- From: rektide <notifications@github.com>
- Date: Fri, 24 Feb 2017 00:31:40 -0800
- To: whatwg/fetch <fetch@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/fetch/issues/447/282234365@github.com>
@annevk I'd like to see `attribute EventHandler onpush` added to FetchObserver (or a PushObserver added, if something makes FetchObserver unsuitable). @stuartp: I think there's some misunderstandings about HTTP/2 Push, [based on your comment](https://github.com/whatwg/fetch/issues/447#issuecomment-275797101) where you said: > That's based on my understanding of HTTP2 Server Push, where pushes aren't inherently tied to any request. If I'm misunderstanding something and they are, like if they're modeled as some kind of subresource of the main response stream, then this'd need some revisiting, but I just checked, and it looks like they're regarded as being effectively independent of any request, so having push-handling be a separate event on ServiceWorkers seems like it'd be the natural design here. In contrast, section [8.2.1 Push Requests](https://tools.ietf.org/html/rfc7540#section-8.2.1) of RFC7540 says: > Pushed responses are always associated with an explicit request the client. The PUSH_PROMISE frames sent by the server are sent on that explicit request's stream. The PUSH_PROMISE frame also includes a promised stream identifier, chosen from the stream identifiers available to the server (see Section 5.1.1). So, Push responses are definitely sent in association with a specific client request. This is used, for example, in [Generic Event Delivery using HTTP Push](https://tools.ietf.org/html/draft-ietf-webpush-protocol-12) (aka webpush), where a client POSTs to a `/subscribe` endpoint, which stays open, and expects as long as that connection is open that it can get push responses sent to it associated with that specific outstanding POST. See [4. Subscribing for Push Messages](https://tools.ietf.org/html/draft-ietf-webpush-protocol-12#section-4) for this example use case. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/whatwg/fetch/issues/447#issuecomment-282234365
Received on Friday, 24 February 2017 08:32:17 UTC