From 2bbde91625688374c8d08c088e7c45d4f9394469 Mon Sep 17 00:00:00 2001
From: jrandom
The other advanced network option has to do with reseeding - you should never need to diff --git a/apps/routerconsole/jsp/help.jsp b/apps/routerconsole/jsp/help.jsp index 6449ec93a8..1533f32ff1 100644 --- a/apps/routerconsole/jsp/help.jsp +++ b/apps/routerconsole/jsp/help.jsp @@ -33,7 +33,7 @@ by their binary code license. This product includes software developed by the A (http://www.apache.org/).
Another application you can see on this webpage is I2PTunnel -(your web interface) - a GPL'ed application written by mihi that +(your web interface) - a GPL'ed application written by mihi that lets you tunnel normal TCP/IP traffic over I2P (such as the eepproxy and the irc proxy).
The router by default also includes human's public domain SAM bridge, diff --git a/apps/sam/java/test/net/i2p/sam/TestStreamTransfer.java b/apps/sam/java/test/net/i2p/sam/TestStreamTransfer.java index af7dccc6a2..6dd8c75a6d 100644 --- a/apps/sam/java/test/net/i2p/sam/TestStreamTransfer.java +++ b/apps/sam/java/test/net/i2p/sam/TestStreamTransfer.java @@ -150,7 +150,7 @@ public class TestStreamTransfer { _log.error("Incorrect size read - expected " + payloadSize + " got " + read); return; } - _log.info("Received from the stream " + id + ": [" + new String(payload) + "]"); + _log.info("\n== Received from the stream " + id + ": [" + new String(payload) + "]"); try { Thread.sleep(5*1000); } catch (InterruptedException ie) {} /* // now echo it back @@ -217,7 +217,12 @@ public class TestStreamTransfer { } try { Thread.sleep(5*1000) ; } catch (InterruptedException ie) {} req = "STREAM SEND ID=42 SIZE=10\nBlahBlah!!"; - _log.info("Sending data"); + _log.info("\n** Sending BlahBlah!!"); + out.write(req.getBytes()); + out.flush(); + try { Thread.sleep(5*1000) ; } catch (InterruptedException ie) {} + req = "STREAM SEND ID=42 SIZE=10\nFooBarBaz!"; + _log.info("\n** Sending FooBarBaz!"); out.write(req.getBytes()); out.flush(); try { Thread.sleep(20*1000); } catch (InterruptedException ie) {} diff --git a/apps/streaming/java/src/net/i2p/client/streaming/MessageOutputStream.java b/apps/streaming/java/src/net/i2p/client/streaming/MessageOutputStream.java index 97268a0edb..753f0f57fd 100644 --- a/apps/streaming/java/src/net/i2p/client/streaming/MessageOutputStream.java +++ b/apps/streaming/java/src/net/i2p/client/streaming/MessageOutputStream.java @@ -143,13 +143,21 @@ public class MessageOutputStream extends OutputStream { public void enqueue() { // no need to be overly worried about duplicates - it would just // push it further out - if (!_enqueued) + if (!_enqueued) { SimpleTimer.getInstance().addEvent(_flusher, _passiveFlushDelay); + if (_log.shouldLog(Log.DEBUG)) + _log.debug("Enqueueing the flusher for " + _passiveFlushDelay + "ms out"); + } else { + if (_log.shouldLog(Log.DEBUG)) + _log.debug("NOT enqueing the flusher"); + } _enqueued = true; } public void timeReached() { _enqueued = false; long timeLeft = (_lastBuffered + _passiveFlushDelay - _context.clock().now()); + if (_log.shouldLog(Log.DEBUG)) + _log.debug("flusher time reached: left = " + timeLeft); if (timeLeft > 0) enqueue(); else @@ -160,7 +168,10 @@ public class MessageOutputStream extends OutputStream { boolean sent = false; WriteStatus ws = null; synchronized (_dataLock) { - if ( (_valid > 0) && (_lastBuffered + _passiveFlushDelay > _context.clock().now()) ) { + long flushTime = _lastBuffered + _passiveFlushDelay; + if ( (_valid > 0) && (flushTime < _context.clock().now()) ) { + if (_log.shouldLog(Log.DEBUG)) + _log.debug("doFlush() valid = " + _valid); if ( (_buf != null) && (_dataReceiver != null) ) { ws = _dataReceiver.writeData(_buf, 0, _valid); _written += _valid; @@ -169,6 +180,9 @@ public class MessageOutputStream extends OutputStream { _dataLock.notifyAll(); sent = true; } + } else { + if (_log.shouldLog(Log.DEBUG)) + _log.debug("doFlush() rejected... valid = " + _valid); } } // ignore the ws diff --git a/core/java/src/net/i2p/client/package.html b/core/java/src/net/i2p/client/package.html index 0bba369b1f..2f67c36884 100644 --- a/core/java/src/net/i2p/client/package.html +++ b/core/java/src/net/i2p/client/package.html @@ -27,7 +27,7 @@ but there are three other subpackages that are helpful. Specifically:
The {@link net.i2p.client.I2PSession} implementation itself communicates with diff --git a/history.txt b/history.txt index ae325f69b2..7e98de3032 100644 --- a/history.txt +++ b/history.txt @@ -1,4 +1,9 @@ -$Id: history.txt,v 1.93 2004/12/01 22:20:04 jrandom Exp $ +$Id: history.txt,v 1.94 2004/12/04 18:40:53 jrandom Exp $ + +2004-12-05 jrandom + * Fixed some links in the console (thanks ugha!) and the javadoc + (thanks dinoman!) + * Fix the stream's passive flush timer (oh, its supposed to work?) 2004-12-03 jrandom * Toss in a small pool of threads (3) to execute the events queued up with diff --git a/router/java/src/net/i2p/router/RouterVersion.java b/router/java/src/net/i2p/router/RouterVersion.java index b366e74ed0..71c104a78f 100644 --- a/router/java/src/net/i2p/router/RouterVersion.java +++ b/router/java/src/net/i2p/router/RouterVersion.java @@ -15,9 +15,9 @@ import net.i2p.CoreVersion; * */ public class RouterVersion { - public final static String ID = "$Revision: 1.98 $ $Date: 2004/12/01 22:20:03 $"; + public final static String ID = "$Revision: 1.99 $ $Date: 2004/12/04 18:40:53 $"; public final static String VERSION = "0.4.2.2"; - public final static long BUILD = 2; + public final static long BUILD = 3; public static void main(String args[]) { System.out.println("I2P Router version: " + VERSION); System.out.println("Router ID: " + RouterVersion.ID);