From b7202e47fc75f88ed3e7f17a638cbd72a7304716 Mon Sep 17 00:00:00 2001 From: eyedeekay Date: Wed, 6 Sep 2023 21:04:33 -0400 Subject: [PATCH] Router: set the netDb cleanup jobs to happen every minute --- .../java/src/net/i2p/router/networkdb/CleanupNetDbJob.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/router/java/src/net/i2p/router/networkdb/CleanupNetDbJob.java b/router/java/src/net/i2p/router/networkdb/CleanupNetDbJob.java index 85be933332..abb3d8d79d 100644 --- a/router/java/src/net/i2p/router/networkdb/CleanupNetDbJob.java +++ b/router/java/src/net/i2p/router/networkdb/CleanupNetDbJob.java @@ -1,9 +1,12 @@ -package net.i2p.router; +package net.i2p.router.networkdb; +import net.i2p.router.JobImpl; +import net.i2p.router.RouterContext; import net.i2p.router.networkdb.kademlia.FloodfillNetworkDatabaseSegmentor; public class CleanupNetDbJob extends JobImpl { private final RouterContext ctx; + private static final long RERUN_DELAY_MS = 1 * 60 * 1000; public CleanupNetDbJob(RouterContext context) { super(context); @@ -19,6 +22,7 @@ public String getName() { public void runJob() { FloodfillNetworkDatabaseSegmentor fnds = (FloodfillNetworkDatabaseSegmentor) ctx.netDb(); fnds.removeDeadSubDbs(ctx.clientManager().listClients()); + requeue(RERUN_DELAY_MS); } }