[Bug 26917] For any chunk, progress event should be fired at least in 50ms since the arrival of the chunk

https://www.w3.org/Bugs/Public/show_bug.cgi?id=26917

--- Comment #4 from Takeshi Yoshino <tyoshino@google.com> ---
Is your plan to invoke the task every 50ms regardless of the time chunks
arrive?

It should also work but a little different from ours. Is it for algorithm
simplicity or any other benefit in your mind?

When a new chunk arrives, we check whether there's any task queued to aggregate
progress events. If there is, we just update the progress data stored on the
XHR object. If not, we fire a progress event and queue the task. The task is
scheduled to be run after 50ms. It checks if there's any progress data stored
on the XHR. If not, do nothing. If there is, fire a progress event from the
stored data and queue the task again.

0ms chunkA
10ms chunkB
20ms chunkC
120ms chunkD

Then, we fire a progress event for chunkA at 0ms and one for chunkC at 50ms,
and one for chunkD at 120ms.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Wednesday, 15 October 2014 03:18:36 UTC