Re: [whatwg/fetch] "process request body" is gone (#495)

Thanks.

Either the source of the stream or the reader can notice that event, but XHR is neither of them (the stream is created in https://fetch.spec.whatwg.org/#concept-bodyinit-extract). I think we need one of the following:

 1. Dispatch "process request body" from https://fetch.spec.whatwg.org/#concept-request-transmit-body.
 1. Dispatch "process request body" from https://fetch.spec.whatwg.org/#concept-bodyinit-extract.
 1. Insert a intercepting stream in XHR (i.e., create an identical transform stream in order to detect reading and use pipeTo).
 1. Create a stream in XHR.

What do you think? I prefer the first because it's simpler.

Another problem: Although the source receives the progress notification in a way, it depends on the chunk size. For example, https://fetch.spec.whatwg.org/#concept-bodyinit-extract enqueues one big chunk in the BufferSource case, and the source will not receive any intermediate progress notification.



-- 
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/495#issuecomment-283559242

Received on Thursday, 2 March 2017 07:27:10 UTC