I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Commit 3d91fac2 authored by zzz's avatar zzz
Browse files

* JobQueue, RepublishLeaseSetJob: Out-of-order JobQueue 3rd try to fix

parent aec39768
No related branches found
No related tags found
No related merge requests found
...@@ -561,6 +561,8 @@ public class KademliaNetworkDatabaseFacade extends NetworkDatabaseFacade { ...@@ -561,6 +561,8 @@ public class KademliaNetworkDatabaseFacade extends NetworkDatabaseFacade {
// Don't spam the floodfills. In addition, always delay a few seconds since there may // Don't spam the floodfills. In addition, always delay a few seconds since there may
// be another leaseset change coming along momentarily. // be another leaseset change coming along momentarily.
long nextTime = Math.max(j.lastPublished() + RepublishLeaseSetJob.REPUBLISH_LEASESET_TIMEOUT, _context.clock().now() + PUBLISH_DELAY); long nextTime = Math.max(j.lastPublished() + RepublishLeaseSetJob.REPUBLISH_LEASESET_TIMEOUT, _context.clock().now() + PUBLISH_DELAY);
// remove first since queue is a TreeSet now...
_context.jobQueue().removeJob(j);
j.getTiming().setStartAfter(nextTime); j.getTiming().setStartAfter(nextTime);
_context.jobQueue().addJob(j); _context.jobQueue().addJob(j);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment