Author: j16sdiz
Date: 2008-12-15 04:20:16 +0000 (Mon, 15 Dec 2008)
New Revision: 24343
Modified:
trunk/plugins/XMLSpider/XMLSpider.java
Log:
logging
Modified: trunk/plugins/XMLSpider/XMLSpider.java
===================================================================
--- trunk/plugins/XMLSpider/XMLSpider.java 2008-12-15 04:20:06 UTC (rev
24342)
+++ trunk/plugins/XMLSpider/XMLSpider.java 2008-12-15 04:20:16 UTC (rev
24343)
@@ -447,6 +447,7 @@
*/
private synchronized void makeMainIndex() throws
IOException,NoSuchAlgorithmException {
// Produce the main index file.
+ Logger.minor(this, "Producing top index...");
if (idsByWord.isEmpty()) {
System.out.println("No URIs with words");
@@ -1318,7 +1319,7 @@
synchronized(this) {
if (writingIndex || stopped)
return;
-
+
db.commit();
writingIndex = true;
}
@@ -1326,18 +1327,20 @@
try {
synchronized(this) {
if(!mustWriteIndex) {
- if(Logger.shouldLog(Logger.MINOR,
this)) Logger.minor(this, "Not making index, no data added since last time");
+ Logger.minor(this, "Not making index,
no data added since last time");
return;
}
mustWriteIndex = false;
}
- time_taken = System.currentTimeMillis();
- makeSubIndices();
- if(Logger.shouldLog(Logger.MINOR, this)) Logger.minor(this,
"Producing top index...");
- makeMainIndex();
- time_taken = System.currentTimeMillis() - time_taken;
- tProducedIndex = System.currentTimeMillis();
- if(Logger.shouldLog(Logger.MINOR, this)) Logger.minor(this,
"Made index, took "+time_taken);
+ time_taken = System.currentTimeMillis();
+
+ makeSubIndices();
+ makeMainIndex();
+
+ time_taken = System.currentTimeMillis() - time_taken;
+ tProducedIndex = System.currentTimeMillis();
+
+ Logger.minor(this, "Made index, took " + time_taken);
} finally {
if (!stopped)
scheduleMakeIndex();
_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs