New issue
Advanced search Search tips

Issue 600776 link

Starred by 4 users

Issue metadata

Status: WontFix
Owner:
Closed: Aug 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android , iOS
Pri: 3
Type: Feature



Sign in to add a comment

[Cronet] Add an API to set initial window size for H2

Project Member Reported by xunji...@chromium.org, Apr 5 2016

Issue description

H2's default initial window size is 65535 bytes (https://code.google.com/p/chromium/codesearch#chromium/src/net/spdy/spdy_session.h&l=549). This might cause stalls on connections with a high bandwidth-delay product. 

It is suggested that we expose an API for developers to set SETTINGS_INITIAL_WINDOW_SIZE.
 
Status: Untriaged (was: Available)

Comment 2 by mef@chromium.org, Apr 26 2016

Labels: -Type-Bug Type-Feature
Status: Available (was: Untriaged)
Owner: kapishnikov@chromium.org
Status: Assigned (was: Available)

Comment 4 by sidv@chromium.org, Jun 13 2016

Labels: -Pri-2 Pri-3
Bumping this down to a P3. It'd be nice to get this in milestone beyond M53

Comment 5 by mef@chromium.org, Jun 20 2016

Cc: b...@chromium.org
Labels: OS-iOS
Owner: ----
Status: Available (was: Assigned)
I think we would need this API on both Android and iOS.

Does it make sense to add this as a parameter for CronetEngine, or do we need it on per-UrlRequest basis? 

Do I understand correctly that the initial window size is only used when H2 session is established?
The initial window size advertised by the client determines how much data the server can send on a newly opened stream before waiting for a window update. The initial window size is usually only negotiated at the beginning of a HTTP2 session, but it is used for every new stream.

If Cronet does not provide users a way to set the initial window size or otherwise update flow control, then HTTP2 peers will only be able to send 64kB of data at a time, even if the BDP of the connection is much higher.
Agreed - this is likely needed on CronetEngine. Arguably you'd want to be
able to specify on a per-origin basis but also OK with changing the default
globally.
Cc: -b...@chromium.org
Owner: b...@chromium.org

Comment 9 by b...@chromium.org, Aug 30 2016

Status: Assigned (was: Available)

Comment 10 by b...@chromium.org, Aug 30 2016

Status: WontFix (was: Assigned)
Chromium currently has a session-level window size of 15 MB and a stream-level window size of 6 MB.  It is defined at [1], which sets HttpNetworkSession::Params members, which get passed to SpdySessionPool, which get passed to SpdySession, which sends out the SETTINGS_INITIAL_WINDOW_SIZE value in the initial SETTINGS frame for the stream level window size [2], and sends a WINDOW_UPDATE frame for the session level window size [3], both in SendInitialData().  Also see the spec [4] for more details.

I believe these values guarantee that network bandwidth-delay-product is fully utilized, so I am closing this bug as WontFix.  Some autotuning of window sizes would be desirable, but that's beyond the scope of this issue.


[1] https://cs.chromium.org/chromium/src/net/http/http_network_session.cc?q=kSpdySessionMaxRecvWindowSize
[2] https://cs.chromium.org/chromium/src/net/spdy/spdy_session.cc?q=SETTINGS_INITIAL_WINDOW_SIZE&l=2716
[3] https://cs.chromium.org/chromium/src/net/spdy/spdy_session.cc?q=IncreaseRecvWindowSize&l=2730
[4] http://httpwg.org/specs/rfc7540.html#InitialWindowSize

Sign in to add a comment