Author: toad
Date: 2009-01-24 22:24:04 +0000 (Sat, 24 Jan 2009)
New Revision: 25304
Modified:
branches/db4o/freenet/src/freenet/client/async/SimpleManifestPutter.java
Log:
Make sure it actually gets run
Modified:
branches/db4o/freenet/src/freenet/client/async/SimpleManifestPutter.java
===================================================================
--- branches/db4o/freenet/src/freenet/client/async/SimpleManifestPutter.java
2009-01-24 22:20:48 UTC (rev 25303)
+++ branches/db4o/freenet/src/freenet/client/async/SimpleManifestPutter.java
2009-01-24 22:24:04 UTC (rev 25304)
@@ -453,16 +453,20 @@
return finished || cancelled;
}
+ private final DBJob runGotAllMetadata = new DBJob() {
+
+ public void run(ObjectContainer container, ClientContext
context) {
+ context.jobRunner.removeRestartJob(this,
NativeThread.NORM_PRIORITY, container);
+ innerGotAllMetadata(container, context);
+ }
+
+ };
+
private void gotAllMetadata(ObjectContainer container, ClientContext
context) {
// This can be huge! Run it on its own transaction to minimize
the build up of stuff to commit
// and maximise the opportunities for garbage collection.
- context.jobRunner.queue(new DBJob() {
-
- public void run(ObjectContainer container,
ClientContext context) {
- innerGotAllMetadata(container, context);
- }
-
- }, NativeThread.NORM_PRIORITY, false);
+ context.jobRunner.queueRestartJob(runGotAllMetadata,
NativeThread.NORM_PRIORITY, container);
+ context.jobRunner.queue(runGotAllMetadata,
NativeThread.NORM_PRIORITY, false);
}
private void innerGotAllMetadata(ObjectContainer container,
ClientContext context) {
_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs