Author: toad
Date: 2007-12-08 14:21:22 +0000 (Sat, 08 Dec 2007)
New Revision: 16401

Modified:
   trunk/freenet/src/freenet/node/Node.java
Log:
Why on earth were we sending keepalives every 2.5-5 seconds!?!?!

Modified: trunk/freenet/src/freenet/node/Node.java
===================================================================
--- trunk/freenet/src/freenet/node/Node.java    2007-12-08 13:25:47 UTC (rev 
16400)
+++ trunk/freenet/src/freenet/node/Node.java    2007-12-08 14:21:22 UTC (rev 
16401)
@@ -209,8 +209,9 @@
        public static final int PACKET_SIZE = 1024;
        public static final double DECREMENT_AT_MIN_PROB = 0.25;
        public static final double DECREMENT_AT_MAX_PROB = 0.5;
-       // Send keepalives every 2.5-5.0 seconds
-       public static final int KEEPALIVE_INTERVAL = 2500;
+       // Send keepalives every 14-28 seconds. Comfortably fits within 30 
second timeout.
+       // If the packet is dropped, we will send ack requests etc, so this 
should be fine.
+       public static final int KEEPALIVE_INTERVAL = 14000;
        // If no activity for 30 seconds, node is dead
        public static final int MAX_PEER_INACTIVITY = 60000;
        /** Time after which a handshake is assumed to have failed. */


Reply via email to