New issue
Advanced search Search tips

Issue 700224 link

Starred by 3 users

Issue metadata

Status: Duplicate
Merged: issue 695225
Owner: ----
Closed: Mar 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment

Infinite retry on 408 response code

Project Member Reported by tombergan@chromium.org, Mar 10 2017

Issue description

On a QUIC or HTTP/2 connection, if a request receives a 408 response, the request can be retried an infinite number of times.

Chrome retries 408 if the connection was reused [1]. I believe this logic was added for HTTP/1.1 connections where there is a concern that the server might close Keep-Alive connections prematurely. Chrome wants to retry in case the request will succeed on a fresh connection. However, IsConnectionReused() is basically always true for QUIC [2] and HTTP/2 [3] connections. This results in infinite retry for QUIC and HTTP/2 when the response code is deterministically 408. I suspect there may be a similar bug here [4] although I'm not too familiar with that code.

Contact me privately for a repro.

[1] https://cs.chromium.org/chromium/src/net/http/http_network_transaction.cc?rcl=aa1f961e37c8778191049bca02608cc54f389366&l=1249
[2] https://cs.chromium.org/chromium/src/net/quic/chromium/quic_http_stream.cc?rcl=caca06866f37c79df89cab9a634bb7497177236e&l=373
[3] https://cs.chromium.org/chromium/src/net/spdy/spdy_session.cc?rcl=caca06866f37c79df89cab9a634bb7497177236e&l=1297
[4] https://cs.chromium.org/chromium/src/net/http/http_network_transaction.cc?rcl=258758c687d31cc18e1f9f0395a8714df0187202&l=1599
 

Comment 1 by mmenke@chromium.org, Mar 10 2017

Components: -Internals>Network Internals>Network>QUIC Internals>Network>HTTP2
Owner: ----
This looks like a H2/QUIC bug - you'd get the same behavior if the server repeatedly returned something that gave us ERR_EMPTY_RESPONSE, and we didn't close the socket.  ResetConnectionAndRequestForResend() isn't resetting the connection for either of those protocols.  Looks to me like the other ResetConnectionAndRequestForResend() calls are safe, since they're called either when the connection is no longer usable, or when we modify the request properties so that the retry will have different connection options.

I don't know either protocol well enough to know how to solve this.

Comment 2 by mmenke@chromium.org, Mar 10 2017

Mergedinto: 695225
Status: Duplicate (was: Untriaged)

Sign in to add a comment