New issue
Advanced search Search tips

Issue 871420 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac
Pri: 3
Type: Bug



Sign in to add a comment

Complete request after response headers when started with SimpleURLLoader::DownloadHeadersOnly

Project Member Reported by reillyg@chromium.org, Aug 6

Issue description

The method SimpleURLLoader::DownloadHeadersOnly is used when the issuer of a resource request does not require the response body. This frees the caller from worrying about how large a response body should be accepted.

The current implementation simply discards the response body as it is received and then calls the provided callback. This is inefficient because it means the response body is still sent over the network and the request takes longer to complete. Rather than wait until the body has been downloaded SimpleURLLoader should cancel the request when OnReceiveResponse() is called.

This issue tracks the work necessary to make this possible. The current implementation makes the assumption that OnComplete() will be called for a successful request. There are also fields of the URLLoaderCompletionStatus passed to OnComplete() that are unrelated to the size of the response body and will be unset if we do not wait for this message.
 
Labels: Enterprise-Triaged

Sign in to add a comment