RESOLVED INVALID 202019
Video Element Progressive Download of MP4 Makes Poorly Behaved Network Requests
https://bugs.webkit.org/show_bug.cgi?id=202019
Summary Video Element Progressive Download of MP4 Makes Poorly Behaved Network Requests
Colin McFadden
Reported 2019-09-19 19:06:09 PDT
Created attachment 379186 [details] Inspector showing the range requests We vend MP4 video from AWS S3 buckets, which are displayed using a standard <video> element. WebKit initially buffers a sizable amount of video from the server, and then closes the connection. When it needs to load additional data (as playback progresses), it makes a 206 Partial Content request with a Content-Range requesting the entire remainder of the file. After loading a small amount of data (roughly 2 megabytes in our environment), the connection is aborted. Because the content-range request asked for the entire remainder of the file, and because the connection was aborted, this causes excessive billing and data transfer on the server side. In our environment with AWS S3, a connection in which the WebKit client loads ~2 megabytes will incur ~12 megabytes of billed data. Ideally would set the content-range more accurately according to the data it actually intends to load, or would maintain a single long-running connection to the server (this is the current behavior in Chrome). I can provide a test environment if necessary, but would rather not do so publicly as the testing process could expose us to substantial costs.
Attachments
Inspector showing the range requests (864.42 KB, image/png)
2019-09-19 19:06 PDT, Colin McFadden
no flags
Radar WebKit Bug Importer
Comment 1 2019-09-20 12:22:29 PDT
Alexey Proskuryakov
Comment 2 2019-09-20 12:23:11 PDT
> I can provide a test environment if necessary, but would rather not do so publicly as the testing process could expose us to substantial costs. Please feel free to e-mail me, I will then add the testing details to an Apple internal ticket.
Alexey Proskuryakov
Comment 3 2020-07-03 16:18:37 PDT
Sorry for the delay. This was determined to be an issue in an underlying framework below WebKit, so we can't track it here. It will continues to be tracked by Apple internally.
ae
Comment 4 2021-06-07 07:31:24 PDT
I just stumbled upon this issue as well while implementing 'Range' requests in our webserver. It's quite disturbing to know that this issue probably doubles global internet bandwidth usage and environmental impact! Crazy.
Note You need to log in before you can comment on or make changes to this bug.