* i2ptunnel:

- IRCClient: Use tunnel log instance
      - Server: Full queue log tweak
This commit is contained in:
zzz
2011-02-05 23:21:56 +00:00
parent b08efb6700
commit c38d72d178
5 changed files with 45 additions and 14 deletions

View File

@ -89,9 +89,9 @@ public class I2PTunnelIRCClient extends I2PTunnelClientBase implements Runnable
i2ps = createI2PSocket(clientDest); i2ps = createI2PSocket(clientDest);
i2ps.setReadTimeout(readTimeout); i2ps.setReadTimeout(readTimeout);
StringBuffer expectedPong = new StringBuffer(); StringBuffer expectedPong = new StringBuffer();
Thread in = new I2PAppThread(new IrcInboundFilter(s,i2ps, expectedPong), "IRC Client " + __clientId + " in", true); Thread in = new I2PAppThread(new IrcInboundFilter(s,i2ps, expectedPong, _log), "IRC Client " + __clientId + " in", true);
in.start(); in.start();
Thread out = new I2PAppThread(new IrcOutboundFilter(s,i2ps, expectedPong), "IRC Client " + __clientId + " out", true); Thread out = new I2PAppThread(new IrcOutboundFilter(s,i2ps, expectedPong, _log), "IRC Client " + __clientId + " out", true);
out.start(); out.start();
} catch (Exception ex) { } catch (Exception ex) {
if (_log.shouldLog(Log.ERROR)) if (_log.shouldLog(Log.ERROR))
@ -128,13 +128,13 @@ public class I2PTunnelIRCClient extends I2PTunnelClientBase implements Runnable
private Socket local; private Socket local;
private I2PSocket remote; private I2PSocket remote;
private StringBuffer expectedPong; private StringBuffer expectedPong;
// shadows _log in super() private final Log _log;
private final Log _log = new Log(I2PTunnelIRCClient.class);
public IrcInboundFilter(Socket _local, I2PSocket _remote, StringBuffer pong) { public IrcInboundFilter(Socket _local, I2PSocket _remote, StringBuffer pong, Log log) {
local=_local; local=_local;
remote=_remote; remote=_remote;
expectedPong=pong; expectedPong=pong;
_log = log;
} }
public void run() { public void run() {
@ -207,13 +207,13 @@ public class I2PTunnelIRCClient extends I2PTunnelClientBase implements Runnable
private Socket local; private Socket local;
private I2PSocket remote; private I2PSocket remote;
private StringBuffer expectedPong; private StringBuffer expectedPong;
// shadows _log in super() private final Log _log;
private final Log _log = new Log(I2PTunnelIRCClient.class);
public IrcOutboundFilter(Socket _local, I2PSocket _remote, StringBuffer pong) { public IrcOutboundFilter(Socket _local, I2PSocket _remote, StringBuffer pong, Log log) {
local=_local; local=_local;
remote=_remote; remote=_remote;
expectedPong=pong; expectedPong=pong;
_log = log;
} }
public void run() { public void run() {

View File

@ -302,9 +302,10 @@ public class I2PTunnelServer extends I2PTunnelTask implements Runnable {
try { try {
i2ps.close(); i2ps.close();
} catch (IOException ioe) {} } catch (IOException ioe) {}
if (open && _log.shouldLog(Log.ERROR)) if (open)
_log.error("ServerHandler queue full for " + remoteHost + ':' + remotePort + _log.logAlways(Log.WARN, "ServerHandler queue full, dropping incoming connection to " +
"; increase " + PROP_HANDLER_COUNT + '?', ree); remoteHost + ':' + remotePort +
"; increase server max threads or " + PROP_HANDLER_COUNT);
} }
} else { } else {
// use only for standard servers that can't get slowlorissed! Not for http or irc // use only for standard servers that can't get slowlorissed! Not for http or irc

View File

@ -50,9 +50,11 @@ public class I2PSOCKSIRCTunnel extends I2PSOCKSTunnel {
Socket clientSock = serv.getClientSocket(); Socket clientSock = serv.getClientSocket();
I2PSocket destSock = serv.getDestinationI2PSocket(this); I2PSocket destSock = serv.getDestinationI2PSocket(this);
StringBuffer expectedPong = new StringBuffer(); StringBuffer expectedPong = new StringBuffer();
Thread in = new I2PAppThread(new I2PTunnelIRCClient.IrcInboundFilter(clientSock, destSock, expectedPong), "SOCKS IRC Client " + (++__clientId) + " in", true); Thread in = new I2PAppThread(new I2PTunnelIRCClient.IrcInboundFilter(clientSock, destSock, expectedPong, _log),
"SOCKS IRC Client " + (++__clientId) + " in", true);
in.start(); in.start();
Thread out = new I2PAppThread(new I2PTunnelIRCClient.IrcOutboundFilter(clientSock, destSock, expectedPong), "SOCKS IRC Client " + __clientId + " out", true); Thread out = new I2PAppThread(new I2PTunnelIRCClient.IrcOutboundFilter(clientSock, destSock, expectedPong, _log),
"SOCKS IRC Client " + __clientId + " out", true);
out.start(); out.start();
} catch (SOCKSException e) { } catch (SOCKSException e) {
_log.error("Error from SOCKS connection", e); _log.error("Error from SOCKS connection", e);

View File

@ -1,3 +1,31 @@
2011-02-05 zzz
* .mtn-ignore: New, to make it harder to check in stuff you shouldn't
* BOB: Drop checked-in build dir
* i2psnark:
- Big refactor to support torrents where only the infohash is known
(i.e., added by magnet links)
- Big refactor to use accessors instead of public fields
- Add support for metadata transfer (BEP 9) via the
extension protocol (BEP 10)
- Add support for adding torrents via standard magnet links (BEP 9)
and "maggot" links (http://sponge.i2p/files/maggotspec.txt)
- Add support for peer exchange (i2p_pex)
- Add stubs for future DHT support (BEP 5)
- Add more information on torrent details page;
add details page for single-file torrents
- Make filename filtering consistent (ticket #368)
- Fix add-torrent locking (ticket #371)
- Fix opentracker configuration
- Add several connect-to-self checks
- Add support for using new I2CP bandwidth limiter
- Add support for using new in-session I2CP naming lookups
- Don't expire outbound Piece messages, since we now defer loading the
data from disk
* i2ptunnel:
- Change connect proxy default to outproxy2.h2ik.i2p
- IRCClient: Use tunnel log instance
- Server: Full queue log tweak
2011-02-03 zzz 2011-02-03 zzz
* Build: * Build:
- Remove dup flag files (ticket #316) - Remove dup flag files (ticket #316)

View File

@ -18,7 +18,7 @@ public class RouterVersion {
/** deprecated */ /** deprecated */
public final static String ID = "Monotone"; public final static String ID = "Monotone";
public final static String VERSION = CoreVersion.VERSION; public final static String VERSION = CoreVersion.VERSION;
public final static long BUILD = 2; public final static long BUILD = 3;
/** for example "-test" */ /** for example "-test" */
public final static String EXTRA = ""; public final static String EXTRA = "";