New issue
Advanced search Search tips

Issue 798508 link

Starred by 0 users

Issue metadata

Status: Fixed
Owner:
Closed: Jan 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , iOS , Chrome , Mac , Fuchsia
Pri: 3
Type: Bug

Blocked on:
issue 776415



Sign in to add a comment

Retry request if server resets pushed stream.

Project Member Reported by b...@chromium.org, Jan 2 2018

Issue description

A server might push a stream, then later reset it.  Currently, if the network stack has claimed this pushed stream for a request before it was reset by the server, then the request fails with an error.

However, the request is idempotent, because not only does the server never see the request headers, but in fact, the server never actually knows if the client is reading the pushed stream, or if it ignored it and just never bothered to reset it.  Therefore it is always safe to retry the request.

In order to do this, a new error code ERR_SPDY_PUSHED_STREAM_RESET_BY_SERVER can be returned by SpdySession (which knows if the stream is pushed or client-initiated), and HttpNetworkTransaction can retry the request on this error code.

Note that I am introducing error code ERR_SPDY_PUSHED_STREAM_NOT_AVAILABLE at https://crrev.com/c/829993 for the case when the pushed stream is claimed by HttpStreamFactoryImpl::Job, but by the time SpdyHttpStream::Initialize() is called, the stream is reset by the server.  The request should be retried on this error code as well.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Jan 4 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9693572f8b2f3e3e13794513ad4057ae641757f2

commit 9693572f8b2f3e3e13794513ad4057ae641757f2
Author: Yoav Weiss <yoav@yoav.ws>
Date: Thu Jan 04 16:18:39 2018

Retry request if server resets HTTP/2 pushed stream

When the server sends down a pushed stream and later on cancels it,
there's currently a race condition. If the pushed stream was not
adopted a request is sent for it, but if it was, it currently fails
in a user-visible way.
This CL fixes that by retrying the request if a pushed stream was
adopted and later cancelled.

Bug:  798508 
Change-Id: Ia580cd4bad355cf4c5738e03db8dbfcf80716ae9
Reviewed-on: https://chromium-review.googlesource.com/848776
Reviewed-by: Bence Béky <bnc@chromium.org>
Commit-Queue: Yoav Weiss <yoav@yoav.ws>
Cr-Commit-Position: refs/heads/master@{#527000}
[modify] https://crrev.com/9693572f8b2f3e3e13794513ad4057ae641757f2/net/base/net_error_list.h
[modify] https://crrev.com/9693572f8b2f3e3e13794513ad4057ae641757f2/net/http/http_network_transaction.cc
[modify] https://crrev.com/9693572f8b2f3e3e13794513ad4057ae641757f2/net/spdy/chromium/spdy_network_transaction_unittest.cc
[modify] https://crrev.com/9693572f8b2f3e3e13794513ad4057ae641757f2/net/spdy/chromium/spdy_session.cc
[modify] https://crrev.com/9693572f8b2f3e3e13794513ad4057ae641757f2/net/spdy/chromium/spdy_stream.cc
[modify] https://crrev.com/9693572f8b2f3e3e13794513ad4057ae641757f2/net/spdy/chromium/spdy_stream.h

Comment 2 by b...@chromium.org, Jan 8 2018

Status: Fixed (was: Assigned)
See also https://crrev.com/c/851655.  This bug can now be closed.

Sign in to add a comment