matvp91 / superstreamer

An open, scalable, online streaming setup. All-in-one toolkit from ingest to adaptive video playback. Built for developers in need of video tooling.
https://matvp91.github.io/superstreamer/
Mozilla Public License 2.0
318 stars 12 forks source link

asset-list.json should fetch VAST #33

Closed matvp91 closed 2 weeks ago

matvp91 commented 2 weeks ago

Our current implementation of VMAP support is a bit static, we'd create a session on the stitcher and at that point do everything in 1 take:

We could split this logic, which would make the implementation less static. We'd probably be able to do something like this:

The trick is to have a map between a pairs of START-DATE + AdBreak. It doesn't really matter where these come from (as a first implementation, we derive this from a VMAP), aslong as we can say "for this given startDate, we have this adBreak to serve out", it'll map really well on dynamic playlists (those missing EXT-X-ENDLIST).

As a final remark, there's probably some caching to do to ensure we do not approach an ad server multiple times for a given session id, as they'll return with a different response (ad servers cap results, see the correlator param on Google IMA's ad server). LRU would be nice for this, when a playlist or asset-list is no longer consumed, at some point it'll be removed from memory this way.