Commit Graph

523 Commits

Author SHA1 Message Date
zzz
f0f363e8c3 * Streaming: Fix instantiation failure with blacklist entries,
caused by bad fix for ticket #1070
2013-10-27 17:09:29 +00:00
zzz
ddf761b1f8 * Streaming: Randomize end of first conn limit period
to prevent correlation
2013-10-26 20:45:30 +00:00
zzz
ca45194c30 * Streaming:
- Check blacklist/whitelist before connection limits, so
     a blacklisted peer does not increment the counters
   - Don't increment total throttle if peer is throttled
   - Fix blacklist NPE after config change (ticket #1070)
2013-10-25 14:09:02 +00:00
zzz
255ebe7efb * Streaming: Throw IOE if socket is closed (ticket #1077),
never return null from stream getters
2013-10-17 13:39:00 +00:00
d0f635e30c ticket #1062 - count duplicate packets towards RTT if we have
never sampled it
2013-10-13 17:05:59 +00:00
zzz
45a579403a propagate from branch 'i2p.i2p.zzz.test2' (head 5c1b78bd78845b0c8b90fbb60412c68e7dc4f3e6)
to branch 'i2p.i2p' (head 8bdc25c8e6f40491f20b533d94eacab012adba35)
2013-10-13 11:48:12 +00:00
zzz
74a57abfb4 Streaming:
- Make I2PSocketFull.close() nonblocking; it will now cause any user-side
     writes blocked in I/O (Connection.packetSendChoke()) to throw
     an exception (tickets #629, #1041)
   - Don't ignore InterruptedExceptions; throw InterruptedIOException
   - Back out static disconnect exception
   - MessageInputStream locking fixes
   - Cleanups
 I2PSnark:
   - Close socket before closing output stream to avoid blocking in
     Peer.disconnect(), and prevent Peer.disconnect() loop
2013-10-12 17:39:49 +00:00
c8843a736d make _ackSinceCongestion atomic 2013-10-09 14:08:44 +00:00
e69fefda62 cleanup: remove boolean parameter that is always true 2013-10-09 14:06:16 +00:00
513da3b743 cleanup: remove no-op invocation 2013-10-09 14:04:34 +00:00
zzz
31f117e74c * Data Structures:
- Make Destination and RouterIdentity keys and cert immutable
   - Add Destination cache
2013-10-07 13:04:01 +00:00
zzz
aa171bbaa6 less scary message 2013-10-06 17:07:56 +00:00
zzz
2884df873e * Streaming: Major rework of connection disconnect process. Tickets 1040-1042.
- Prevent multiple calls or reentrancy in disconnect() (ticket #1041)
   - Implement processing of close to skip TIME-WAIT, and
     wait for all packets to be acked (not just the CLOSE) before
     doing so, if possible (ticket #1042)
   - Don't call disconnect() or disconnectComplete() from I2PSocketFull.destroy()
     so retransmissions and acks can still happen (removes some close loops)
   - Don't call disconnect() until we have both sent and received a CLOSE (ticket #1040)
   - Don't reset the connection from CPH just because we sent a CLOSE
     and it was acked (ticket #1040)
   - Ack packets even if we sent a CLOSE  (ticket #1040)
   - Retransmit CLOSE if not acked (ticket #1040)
   - Send received packets to the MessageInputStream even if we haven't received a SYN
   - Don't call MessageInputStream.messageReceived() for ack-only packets, that was pointless
   - Don't send a RESET after timeout of an outbound connection
   - Work around bugs on other end by limiting retransmission of CLOSE packets
   - Make _isInbound final
   - More cleanups, javadocs, log tweaks
2013-09-28 11:47:47 +00:00
zzz
30a666c833 Streaming: Don't queue a message for an unknown connection on the SYN queue
if it has a send ID set, it must be for a recently closed connection
2013-09-27 01:50:38 +00:00
zzz
9a00621fa4 log tweaks 2013-09-27 01:48:12 +00:00
zzz
25682fdea7 log tweaks, javadoc 2013-09-25 17:42:13 +00:00
zzz
9318099845 * Streaming:
- Cleanups
   - Remove setCloseReceivedOn(), unused outside Connection
   - OR the isFlagSet parameter instead of multiple calls
   - Remove acked packets from _outboundPackets inside synced iterator
   - Short-circuit _outboundPackets iterator if empty
   - Small optimization if not logging in ConnectionPacketHandler
   - Stub out processing of close ack (ticket #1042)
2013-09-24 16:01:20 +00:00
zzz
fdf38a952d atomic default value cleanup 2013-09-24 14:45:30 +00:00
zzz
fb40ab1f00 * Streaming: Atomics for close/reset send/receive
so we only do things once. (Ticket #1041)
2013-09-24 14:01:48 +00:00
zzz
3499ed7bb0 * Streaming: Consolidate scheduling of DisconnectEvent, and ensure
we only do it once. (Ticket #1041)
2013-09-24 13:22:46 +00:00
zzz
61d5f46295 * Streaming: Fix active stream counting so it doesn't count streams
that are closed and in TIME-WAIT state. Also, break out of the
   counting loop as soon as we know the answer. (Ticket #1039)
2013-09-24 12:40:35 +00:00
592680302f make the logCloseLoop() methods members of the Log class
so they can be used everywhere
2013-09-08 12:55:05 +00:00
6812dc1db8 Ticket #1007 use only non-retransmitted packets in RTT
sampling.  (RFC 6298)
2013-08-31 18:39:29 +00:00
def30c5903 javadoc update 2013-08-14 20:29:40 +00:00
193f0bbc42 More elegant 2013-08-11 20:21:06 +00:00
fd297118f9 fix NPE if stats are not enabled 2013-08-11 11:58:51 +00:00
1f3227409b Reduce initial ack delay to 1000
Rework the logic for acking duplicate packets
2013-08-10 21:03:05 +00:00
afda1da9c3 volatile 2013-08-10 21:00:09 +00:00
zzz
e3f02553fd javadoc 2013-07-28 12:52:10 +00:00
dd181a90e1 Fix NPE when cancelling PacketLocal's 2013-07-25 20:07:12 +00:00
a1c724f866 reduce initialRTO to 9000 2013-07-23 14:18:51 +00:00
96609e9173 change default loglevel for duplicate close()s to INFO 2013-07-23 14:17:26 +00:00
zzz
90cc71d14d propagate from branch 'i2p.i2p.zzz.test2' (head d80f8632ef0a2aa350eee9a38ba6a4c56471f5bc)
to branch 'i2p.i2p' (head e8b712c826e44211217f06eb3a4da2703323a42f)
2013-07-20 11:53:41 +00:00
zzz
8505e8a1ca fix streaming property 2013-07-19 21:28:14 +00:00
96de87fdde compute rttDev in updateRTT 2013-07-18 22:33:23 +00:00
55d571ffec Hardcode TCP constants
Various suggestions by zzz
2013-07-18 22:25:10 +00:00
ae347c4fa1 sync getters 2013-07-18 15:52:40 +00:00
018098b8ef better loading from cache 2013-07-18 01:52:46 +00:00
171f0d2671 Implement RTT update on first ack 2013-07-17 21:13:19 +00:00
8937c4bf2a Store stdev of rtt in the TCB cache as per RFC 2140 2013-07-17 18:13:42 +00:00
zzz
732eddd1b9 toString() fix (NO_ACK) 2013-07-10 18:14:18 +00:00
67859f67b0 Make activeResends field atomic 2013-07-09 13:55:09 +00:00
aab4a3ab44 Change criteria for resending on NACK to match comment 2013-07-07 20:13:11 +00:00
e9e550fb55 cleanup, sync, more logging 2013-07-07 19:15:08 +00:00
f80ea386a0 Log errors to logger if available 2013-07-07 17:20:06 +00:00
bec62c1be7 Remove unused field
Use atomics to manage closed state and IOExceptions
2013-07-05 19:48:31 +00:00
7f8efca0ba minor cleanup, more to follow 2013-07-05 19:05:54 +00:00
76de4faf62 better sync 2013-07-05 18:29:00 +00:00
dfc4948a6f cleanup & sync 2013-07-05 18:21:42 +00:00
ba0e58e66a fix compilation 2013-07-05 12:53:13 +00:00