Permalink
Browse files

CCID opens in OPEN. CLOSING timer shorter.

  • Loading branch information...
1 parent 5b5e60b commit 12c05fb108fb20bdb376c43f5f09852dc1591ca3 @petar committed Nov 20, 2011
Showing with 10 additions and 8 deletions.
  1. +6 −0 dccp/NOTES
  2. +1 −6 dccp/TESTING
  3. +2 −1 dccp/goto.go
  4. +1 −1 dccp/socket.go
View
@@ -0,0 +1,6 @@
+
+* We don't start CCID in PARTOPEN (rather wait until OPEN), because
+in PARTOPEN the client still needs to send (Ack,Sync) packet pairs,
+but the initial CCID rate is 1 packet per second, which slows down
+the handshake to OPEN, since the second packet of the (Ack,Sync)
+sequence has to wait for a whole second.
View
@@ -1,10 +1,5 @@
-* after 1sec, CCID has not been open on server
-
-* why does packet exchange stop in 6 seconds
- * because OnIdle is not called regularly, which is the case because SetReadTimeout is not
- implemented by the HeaderConn.
- * Add a runtime check in readLoop that SetReadTimeout works roughly correctly?
+* implement SetReadTimeout
* ensure behavior stabilizes if both sides remain silent after connect and connection does not close
perpetually
View
@@ -117,7 +117,7 @@ func (c *Conn) gotoPARTOPEN() {
c.AssertLocked()
c.socket.SetState(PARTOPEN)
c.emitSetState()
- c.openCCID()
+ // c.openCCID()
c.inject(nil) // Unblocks the writeLoop select, so it can see the state change
// Start PARTOPEN timer, according to Section 8.1.5
@@ -181,6 +181,7 @@ func (c *Conn) gotoCLOSING() {
c.Lock()
rtt := c.socket.GetRTT()
c.Unlock()
+ c.Logger.Emit("conn", "Event", nil, "CLOSING RTT=%dns", rtt)
b := newBackOff(2*rtt, CLOSING_BACKOFF_MAX, CLOSING_BACKOFF_FREQ)
for {
err, _ := b.Sleep()
View
@@ -76,7 +76,7 @@ const (
RTT_MIN = 2e6 // ...
MSL = 2 * 60e9 // 2 mins in nanoseconds, Maximum Segment Lifetime, Section 3.4
CLOSING_BACKOFF_FREQ = 64e9 // Backoff frequency of CLOSING timer, 64 seconds, Section 8.3
- CLOSING_BACKOFF_MAX = MSL // Maximum amount of time in CLOSING timer
+ CLOSING_BACKOFF_MAX = MSL/4 // Maximum time in CLOSING (RFC recommends MSL, but seems too long)
MAX_OPTIONS_SIZE = 128
)

0 comments on commit 12c05fb

Please sign in to comment.