muxinc / mux-stats-google-ima

Other
4 stars 4 forks source link

[Feature]: Ad break events #29

Open andrewjl-mux opened 9 months ago

andrewjl-mux commented 9 months ago

Forward ad break events received from the IMA SDK.

daytime-em commented 6 months ago

oops, wrong issue. automatically collecting these is something else

daytime-em commented 6 months ago

Clarification: These events are sent, but require manual intervention on the part of the caller. This is documented in the dev docs. The caller has to call onContentPauseOrResume in some boilerplate at the right time. This design isn't ideal, but is a consequence of the fact that there can only be one IMAAdsLoaderDelegate and one IMAAdsManagerDelegate, etc set on Google's objects.

One thing we can try is to weakly hold the customer's delegates and call their methods after doing our own handling (ie, the stuff that currently happens in onContentPauseOrResume). This isn't blocking any of our initiatives, but it would definitely be nice to have (and match the media3 integration)

wdyt @andrewjl-mux ?