Re: [whatwg] HTTP/2 push detection and control in JavaScript

On Tue, Feb 24, 2015 at 9:32 AM, Brendan Long <self@brendanlong.com> wrote:

> HTTP/2 associates priority information with HEADERS
> <http://http2.github.io/http2-spec/#HEADERS> (but as a flag, not as a
> normal header), so maybe it would make sense to add this to Fetch's
> Headers <https://fetch.spec.whatwg.org/#headers-class>. I'm not sure if
> it makes sense to put it on Request
> <https://fetch.spec.whatwg.org/#request-class>, since it seems to only
> expose readonly attributes.
>

HTTP/2 allows reprioritization via PRIORITY frame [1], so this is something
we should account for in the API. E.g. application starts fetching an image
(high priority fetch) but the user advances to the next image in the
gallery, at which point the applications want to reprioritize the initial
fetch such that it still completes and gets cached, but doesn't compete
with new+other fetches that are of higher priority.

[1] http://http2.github.io/http2-spec/#PRIORITY

Received on Friday, 27 February 2015 22:43:11 UTC