Skip to content

Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance

*) deleting empty entities during index selection

theli3631cb1f6dcb
diff --git a/source/de/anomic/plasma/plasmaWordIndexDistribution.java b/source/de/anomic/plasma/plasmaWordIndexDistribution.java
index 77d005579..c2a5242f8 100644
--- a/source/de/anomic/plasma/plasmaWordIndexDistribution.java
+++ b/source/de/anomic/plasma/plasmaWordIndexDistribution.java
@@ -378,6 +378,13 @@ public final class plasmaWordIndexDistribution {
indexEntity.removeEntry(nextUrlHash, true);
this.urlPool.loadedURL.remove(nextUrlHash);
}
+
+ // deleting entity if there are no more entries left
+ // This could occure if there are unknownURLs in the entity
+ if (indexEntity.size() == 0) {
+ indexEntity.deleteComplete();
+ }
+
// use whats remaining
this.log.logFine("Selected partial index (" + tmpEntity.size() + " from " + indexEntity.size() +" URLs, " + unknownURLEntries.size() + " not bound) for word " + tmpEntity.wordHash());
tmpEntities.add(tmpEntity);
diff --git a/source/yacy.java b/source/yacy.java
index 2b9204c1b..ea7567bf6 100644
--- a/source/yacy.java
+++ b/source/yacy.java
@@ -626,7 +626,7 @@ public final class yacy {
while (words.hasMoreElements()) try {
wordfile = (File) words.nextElement();
wordhash = wordfile.getName().substring(0, 12);
- System.out.println("NOW: " + wordhash);
+ //System.out.println("NOW: " + wordhash);
migrationStatus = wordIndexCache.migrateWords2Assortment(wordhash);
if (migrationStatus instanceof Integer) {
int migrationCount = ((Integer)migrationStatus).intValue();