Skip to content

Commit

Permalink
increase initialWindowSize and initialConnWindowSize by 2048.
Browse files Browse the repository at this point in the history
Improves throughput by 5x.

Partially addresses #1043.
  • Loading branch information
glycerine committed Mar 27, 2017
1 parent 14a6be4 commit edd14bc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions transport/control.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ import (

const (
// The default value of flow control window size in HTTP2 spec.
defaultWindowSize = 65535
defaultWindowSize = 65536
// The initial window size for flow control.
initialWindowSize = defaultWindowSize // for an RPC
initialConnWindowSize = defaultWindowSize * 16 // for a connection
initialWindowSize = defaultWindowSize * 2048 // for an RPC
initialConnWindowSize = defaultWindowSize * 16 * 2048 // for a connection
infinity = time.Duration(math.MaxInt64)
defaultClientKeepaliveTime = infinity
defaultClientKeepaliveTimeout = time.Duration(20 * time.Second)
Expand Down

0 comments on commit edd14bc

Please sign in to comment.