diff --git a/apps/streaming/java/src/net/i2p/client/streaming/impl/Connection.java b/apps/streaming/java/src/net/i2p/client/streaming/impl/Connection.java index 8cec3cad8..58f4d5e00 100644 --- a/apps/streaming/java/src/net/i2p/client/streaming/impl/Connection.java +++ b/apps/streaming/java/src/net/i2p/client/streaming/impl/Connection.java @@ -85,7 +85,7 @@ class Connection { private long _lifetimeDupMessageReceived; public static final long MAX_RESEND_DELAY = 45*1000; - public static final long MIN_RESEND_DELAY = 2*1000; + public static final long MIN_RESEND_DELAY = 1000; /** * Wait up to 5 minutes after disconnection so we can ack/close packets. diff --git a/apps/streaming/java/src/net/i2p/client/streaming/impl/MessageOutputStream.java b/apps/streaming/java/src/net/i2p/client/streaming/impl/MessageOutputStream.java index 681c77b7f..c675812a6 100644 --- a/apps/streaming/java/src/net/i2p/client/streaming/impl/MessageOutputStream.java +++ b/apps/streaming/java/src/net/i2p/client/streaming/impl/MessageOutputStream.java @@ -50,7 +50,7 @@ class MessageOutputStream extends OutputStream { * Since this is less than i2ptunnel's i2p.streaming.connectDelay default of 1000, * we only wait 250 at the start. Guess that's ok, 1000 is too long anyway. */ - private static final int DEFAULT_PASSIVE_FLUSH_DELAY = 250; + private static final int DEFAULT_PASSIVE_FLUSH_DELAY = 175; /**** public MessageOutputStream(I2PAppContext ctx, DataReceiver receiver) { diff --git a/history.txt b/history.txt index 266630398..8dd4cdb7e 100644 --- a/history.txt +++ b/history.txt @@ -4,6 +4,10 @@ - Include in update, use version in base dir too - Increase limits - Bug fixes + * Latency reduction all over: + - SSU: Reduce ack delay + - Streaming: Reduce min RTO and flusher delay + - Tunnels: Reduce GW batching time * UrlLauncher: - Configure browser with routerconsole.browser (ticket #1159) - Convert to ClientApp interface diff --git a/router/java/src/net/i2p/router/transport/udp/ACKSender.java b/router/java/src/net/i2p/router/transport/udp/ACKSender.java index f2ca91fc8..a94572ace 100644 --- a/router/java/src/net/i2p/router/transport/udp/ACKSender.java +++ b/router/java/src/net/i2p/router/transport/udp/ACKSender.java @@ -28,7 +28,7 @@ class ACKSender implements Runnable { private static final long POISON_PS = -9999999999l; /** how frequently do we want to send ACKs to a peer? */ - static final int ACK_FREQUENCY = 350; + static final int ACK_FREQUENCY = 250; public ACKSender(RouterContext ctx, UDPTransport transport) { _context = ctx; diff --git a/router/java/src/net/i2p/router/tunnel/BatchedRouterPreprocessor.java b/router/java/src/net/i2p/router/tunnel/BatchedRouterPreprocessor.java index 3d62ded4b..702719931 100644 --- a/router/java/src/net/i2p/router/tunnel/BatchedRouterPreprocessor.java +++ b/router/java/src/net/i2p/router/tunnel/BatchedRouterPreprocessor.java @@ -24,11 +24,11 @@ class BatchedRouterPreprocessor extends BatchedPreprocessor { /** This goes in router advanced config */ public static final String PROP_ROUTER_BATCH_FREQUENCY = "router.batchFrequency"; /** for client OBGWs only (our data) */ - public static final int OB_CLIENT_BATCH_FREQ = 100; + public static final int OB_CLIENT_BATCH_FREQ = 75; /** for exploratory OBGWs only (our tunnel tests and build messages) */ - public static final int OB_EXPL_BATCH_FREQ = 150; + public static final int OB_EXPL_BATCH_FREQ = 100; /** for IBGWs for efficiency (not our data) */ - public static final int DEFAULT_BATCH_FREQUENCY = 250; + public static final int DEFAULT_BATCH_FREQUENCY = 175; /** for OBGWs */ public BatchedRouterPreprocessor(RouterContext ctx, TunnelCreatorConfig cfg) {