Author: j16sdiz
Date: 2008-12-18 04:26:22 +0000 (Thu, 18 Dec 2008)
New Revision: 24504
Modified:
trunk/plugins/XMLSpider/XMLSpider.java
Log:
proper terminate
Modified: trunk/plugins/XMLSpider/XMLSpider.java
===================================================================
--- trunk/plugins/XMLSpider/XMLSpider.java 2008-12-18 04:26:12 UTC (rev
24503)
+++ trunk/plugins/XMLSpider/XMLSpider.java 2008-12-18 04:26:22 UTC (rev
24504)
@@ -26,7 +26,6 @@
import java.util.Map;
import java.util.Set;
import java.util.Vector;
-import java.util.concurrent.Executor;
import java.util.concurrent.PriorityBlockingQueue;
import java.util.concurrent.ThreadPoolExecutor;
import java.util.concurrent.TimeUnit;
@@ -415,7 +414,7 @@
// this is java.util.concurrent.Executor, not freenet.support.Executor
// always run with one thread --> more thread cause contention and
slower!
- protected Executor callbackExecutor = new ThreadPoolExecutor( //
+ protected ThreadPoolExecutor callbackExecutor = new ThreadPoolExecutor(
//
1, 1, 600, TimeUnit.SECONDS, new
PriorityBlockingQueue<Runnable>(5, new CallbackPrioritizer()));
/**
@@ -1033,6 +1032,7 @@
me.getValue().cancel();
}
runningFetch.clear();
+ callbackExecutor.shutdownNow();
}
}
_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs