Changeset a2f027e


Ignore:
Timestamp:
Mar 18, 2015 7:58:31 PM (6 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
8742a66
Parents:
cb4359c
Message:

NetDB: Don't publish non-ff RI on exit if we are coming right back

Location:
router/java/src/net/i2p/router/networkdb/kademlia
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • router/java/src/net/i2p/router/networkdb/kademlia/FloodfillMonitorJob.java

    rcb4359c ra2f027e  
    3535    private static final int MIN_FF = 5000;
    3636    private static final int MAX_FF = 999999;
    37     private static final String PROP_FLOODFILL_PARTICIPANT = "router.floodfillParticipant";
     37    static final String PROP_FLOODFILL_PARTICIPANT = "router.floodfillParticipant";
    3838   
    3939    public FloodfillMonitorJob(RouterContext context, FloodfillNetworkDatabaseFacade facade) {
  • router/java/src/net/i2p/router/networkdb/kademlia/FloodfillNetworkDatabaseFacade.java

    rcb4359c ra2f027e  
    9595    @Override
    9696    public synchronized void shutdown() {
    97         if (_floodfillEnabled) {
     97        // only if not forced ff or not restarting
     98        if (_floodfillEnabled &&
     99            (!_context.getBooleanProperty(FloodfillMonitorJob.PROP_FLOODFILL_PARTICIPANT) ||
     100             !(_context.router().scheduledGracefulExitCode() == Router.EXIT_HARD_RESTART ||
     101               _context.router().scheduledGracefulExitCode() == Router.EXIT_GRACEFUL_RESTART))) {
    98102            // turn off to build a new RI...
    99103            _floodfillEnabled = false;
Note: See TracChangeset for help on using the changeset viewer.