[Webkit-unassigned] [Bug 250548] New: Excessive 'timeupdate' events triggered by video element with HLS streams carrying in-band EMSG metadata

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jan 13 00:19:29 PST 2023


https://bugs.webkit.org/show_bug.cgi?id=250548

            Bug ID: 250548
           Summary: Excessive 'timeupdate' events triggered by video
                    element with HLS streams carrying in-band EMSG
                    metadata
           Product: WebKit
           Version: Safari 16
          Hardware: Mac (Apple Silicon)
                OS: macOS 13
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: Media
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: jameson.steiner at bitmovin.com

Created attachment 464479

  --> https://bugs.webkit.org/attachment.cgi?id=464479&action=review

HTML page loading an HLS stream carrying EMSG metadata into a video element and enabling the metadata track. Logging out 'timeupdate' events during playback to observe the issue.

When playing HLS streams carrying EMSG in-band metadata, excessive/duplicate 'timeupdate' events would be fired by the video element if the respective metadata track is enabled.

Observations:
1. If the metadata track's 'mode' property is set to 'disabled' (default) the browser does not process the track at all as per the API spec and 'timeupdate' events from the video element are observed in normal 250ms intervals.
2. Once the track is enabled by setting its mode to 'hidden', excessive 'timeupdate' events are triggered by the video element. Looking at the timing of the events it looks like some of them are triggered at the exact same time, i.e. are duplicates.

This causes event handlers on the 'timeupdate' event to be called more often and thereby also causes more load on the device. In the attached reproduction case, around twice as many events are fired if the metadata track is enabled. Furthermore, with a stream of one of our customers that also carries a lot of EMSG metadata (but we cannot share publically), we are seeing around 750 'timeupdate' events within a 10-second period of playback if the metadata track is enabled vs. 40 events if the track is disabled. Additionally, with that stream, we are seeing CPU utilization and memory consumption steadily rising during playback up to a point (after around 1 hr) that Safari shows a banner saying "This web page is using significant memory. Closing it may improve the responsiveness of your Mac." and the page becomes very unresponsive. This is also only observed if the metadata track is enabled.

Reproduction case:
Attached is a simple HTML page loading an HLS stream that carries EMSG metadata into a video element and enabling the metadata track. Start playback and observe logged 'timeupdate' events in the browser console during playback. After 15 seconds playback is finished and the total count of received 'timeupdate' events is logged out. Different behavior can be observed depending on whether the metadata track is enabled or not.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20230113/f1a9d40e/attachment.htm>


More information about the webkit-unassigned mailing list