2005-02-22 jrandom

* Temporary workaround for the I2CP disconnect bug (have the streaminglib
      try to automatically reconnect on accept()/connect(..)).
    * Loop check for expired lease republishing (just in case)
This commit is contained in:
jrandom
2005-02-22 22:58:21 +00:00
committed by zzz
parent c17433cb93
commit b8291ac5a4
5 changed files with 20 additions and 9 deletions

View File

@ -15,9 +15,9 @@ import net.i2p.CoreVersion;
*
*/
public class RouterVersion {
public final static String ID = "$Revision: 1.145 $ $Date: 2005/02/21 13:02:16 $";
public final static String ID = "$Revision: 1.146 $ $Date: 2005/02/22 02:07:33 $";
public final static String VERSION = "0.5";
public final static long BUILD = 4;
public final static long BUILD = 5;
public static void main(String args[]) {
System.out.println("I2P Router version: " + VERSION);
System.out.println("Router ID: " + RouterVersion.ID);

View File

@ -227,7 +227,10 @@ public class ClientConnectionRunner {
}
void disconnectClient(String reason) {
_log.error("Disconnecting the client: " + reason);
if (_log.shouldLog(Log.CRIT))
_log.log(Log.CRIT, "Disconnecting the client ("
+ _config.getDestination().calculateHash().toBase64().substring(0,4)
+ ": " + reason);
DisconnectMessage msg = new DisconnectMessage();
msg.setReason(reason);
try {

View File

@ -74,9 +74,11 @@ public class RepublishLeaseSetJob extends JobImpl {
public OnFailure(RouterContext ctx) { super(ctx); }
public String getName() { return "Publish leaseSet failed"; }
public void runJob() {
if (_log.shouldLog(Log.ERROR))
_log.error("FAILED publishing of the leaseSet for " + _dest.toBase64());
getContext().jobQueue().addJob(new RepublishLeaseSetJob(getContext(), _facade, _dest));
if (_log.shouldLog(Log.WARN))
_log.warn("FAILED publishing of the leaseSet for " + _dest.toBase64());
LeaseSet ls = _facade.lookupLeaseSetLocally(_dest);
if ( (ls != null) && (ls.isCurrent(0)) )
getContext().jobQueue().addJob(new RepublishLeaseSetJob(getContext(), _facade, _dest));
}
}
}