From 351bd0a67890e7bf01805e016295954b562549c7 Mon Sep 17 00:00:00 2001 From: hermens Date: Mon, 27 Feb 2006 01:58:37 +0000 Subject: [PATCH] *) dbImport: convert cacheSize to kb when creating plasma* objects git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@1773 6c8d7289-2bf4-0310-a012-ef5d649a1542 --- source/de/anomic/plasma/dbImport/plasmaCrawlNURLImporter.java | 4 ++-- source/de/anomic/plasma/dbImport/plasmaDbImporter.java | 4 ++-- .../plasma/dbImport/plasmaWordIndexAssortmentImporter.java | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/source/de/anomic/plasma/dbImport/plasmaCrawlNURLImporter.java b/source/de/anomic/plasma/dbImport/plasmaCrawlNURLImporter.java index c16477fb1..5508717ad 100644 --- a/source/de/anomic/plasma/dbImport/plasmaCrawlNURLImporter.java +++ b/source/de/anomic/plasma/dbImport/plasmaCrawlNURLImporter.java @@ -89,13 +89,13 @@ public class plasmaCrawlNURLImporter extends AbstractImporter implements // init noticeUrlDB this.log.logInfo("Initializing the source noticeUrlDB"); - this.importNurlDB = new plasmaCrawlNURL(this.importPath, this.cacheSize*(3/4)); + this.importNurlDB = new plasmaCrawlNURL(this.importPath, ((this.cacheSize*3)/4)/1024); this.importStartSize = this.importNurlDB.size(); //int stackSize = this.importNurlDB.stackSize(); // init profile DB this.log.logInfo("Initializing the source profileDB"); - this.importProfileDB = new plasmaCrawlProfile(profileDbFile,this.cacheSize*(1/3)); + this.importProfileDB = new plasmaCrawlProfile(profileDbFile, ((this.cacheSize*1)/4)/1024); } public void run() { diff --git a/source/de/anomic/plasma/dbImport/plasmaDbImporter.java b/source/de/anomic/plasma/dbImport/plasmaDbImporter.java index a51db1baf..dbd3916f1 100644 --- a/source/de/anomic/plasma/dbImport/plasmaDbImporter.java +++ b/source/de/anomic/plasma/dbImport/plasmaDbImporter.java @@ -75,9 +75,9 @@ public class plasmaDbImporter extends AbstractImporter implements dbImporter { } this.log.logFine("Initializing source word index db."); - this.importWordIndex = new plasmaWordIndex(this.importPath, this.cacheSize/2, this.log); + this.importWordIndex = new plasmaWordIndex(this.importPath, (this.cacheSize/2)/1024, this.log); this.log.logFine("Initializing import URL db."); - this.importUrlDB = new plasmaCrawlLURL(new File(this.importPath, "urlHash.db"), this.cacheSize/2); + this.importUrlDB = new plasmaCrawlLURL(new File(this.importPath, "urlHash.db"), (this.cacheSize/2)/1024); this.importStartSize = this.importWordIndex.size(); } diff --git a/source/de/anomic/plasma/dbImport/plasmaWordIndexAssortmentImporter.java b/source/de/anomic/plasma/dbImport/plasmaWordIndexAssortmentImporter.java index c84915bbf..33b8a6be2 100644 --- a/source/de/anomic/plasma/dbImport/plasmaWordIndexAssortmentImporter.java +++ b/source/de/anomic/plasma/dbImport/plasmaWordIndexAssortmentImporter.java @@ -60,7 +60,7 @@ public class plasmaWordIndexAssortmentImporter extends AbstractImporter implemen // initializing the import assortment db this.log.logInfo("Initializing source assortment file"); - this.assortmentFile = new plasmaWordIndexAssortment(importAssortmentPath,assortmentNr,8*1024*1024, this.log); + this.assortmentFile = new plasmaWordIndexAssortment(importAssortmentPath,assortmentNr, this.cacheSize/1024, this.log); this.importStartSize = this.assortmentFile.size(); }