forked from I2P_Developers/i2p.i2p
Sybil: Refactoring part 5
Make Analysis class singleton, hang off ClientAppManager prep for offline scheduling
This commit is contained in:
@@ -34,6 +34,7 @@ import net.i2p.jetty.I2PLogger;
|
||||
import net.i2p.router.RouterContext;
|
||||
import net.i2p.router.app.RouterApp;
|
||||
import net.i2p.router.news.NewsManager;
|
||||
import net.i2p.router.sybil.Analysis;
|
||||
import net.i2p.router.update.ConsoleUpdateManager;
|
||||
import net.i2p.util.Addresses;
|
||||
import net.i2p.util.FileSuffixFilter;
|
||||
@@ -865,6 +866,13 @@ public class RouterConsoleRunner implements RouterApp {
|
||||
if (_mgr == null)
|
||||
_context.addShutdownTask(new ServerShutdown());
|
||||
ConfigServiceHandler.registerSignalHandler(_context);
|
||||
|
||||
if (_mgr != null &&
|
||||
_context.getBooleanProperty(HelperBase.PROP_ADVANCED) &&
|
||||
_context.getProperty(Analysis.PROP_FREQUENCY, 0L) > 0) {
|
||||
// registers and starts itself
|
||||
Analysis.getInstance(_context);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user