Bug 18963 - Provide a mechanism for rate limiting appending
Summary: Provide a mechanism for rate limiting appending
Alias: None
Product: HTML WG
Classification: Unclassified
Component: Media Source Extensions (show other bugs)
Version: unspecified
Hardware: PC Windows 3.1
: P1 normal
Target Milestone: ---
Assignee: Aaron Colwell (c)
QA Contact: HTML WG Bugzilla archive list
Whiteboard: tpac2012
Depends on:
Blocks: 20253
  Show dependency treegraph
Reported: 2012-09-21 22:28 UTC by Aaron Colwell (c)
Modified: 2012-12-06 01:57 UTC (History)
3 users (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Aaron Colwell (c) 2012-09-21 22:28:51 UTC
This bug is the result of discussions around Bug 16998


Currently there is no mechanism for the UA to signal that it wants the web application to stop appending for a while. A UA might want to do this in a memory constrained environment to help the web application avoid appending "too far ahead" which might trigger media segment eviction (Section 2.10). 

It could be useful to have a mechanism that notifies the application when further appends will trigger evictions so the web application could use remove() (https://www.w3.org/Bugs/Public/show_bug.cgi?id=18709) to control what time ranges get removed. When the UA determines that enough data has been removed to allow appending again it can notify the application with an event.
Comment 1 Aaron Colwell (c) 2012-12-05 19:09:02 UTC
Based on discussions at TPAC (http://www.w3.org/2012/11/01-html-wg-minutes.html), it was decided to have append() throw an exception when the SourceBuffer is full. The application can use remove() to free up space in the buffer and try again.

I plan on updating the spec text for append() to say that a QUOTA_EXCEEDED_ERR should be thrown if the SourceBuffer doesn't have space available to accommodate the data in the append.
Comment 2 Aaron Colwell (c) 2012-12-06 01:57:00 UTC
Changes committed