Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stuck media playback with VPAID ads #7832

Closed
chladto1 opened this issue Aug 31, 2020 · 6 comments
Closed

Stuck media playback with VPAID ads #7832

chladto1 opened this issue Aug 31, 2020 · 6 comments
Assignees
Labels

Comments

@chladto1
Copy link

[REQUIRED] Issue description

VPAID ads are not supported by IMA, but it look like, IMA is correctly sending event CONTENT_RESUME_REQUESTED, but the media playback is stuck anyway. Could you please fix it?

[REQUIRED] Reproduction steps

Use the following VMAP as adTagUri.

[REQUIRED] Link to test content

https://devs.origin.cdn.cra.cz/ima/vpaidvmap.xml

[REQUIRED] A full bug report captured from the device

log.txt

[REQUIRED] Version of ExoPlayer being used

2.11.8

[REQUIRED] Device(s) and version(s) of Android being used

Device or Android version independent.

@christosts
Copy link
Contributor

@andrewlewis can you please take a look?

@christosts christosts removed the bug label Sep 1, 2020
@andrewlewis
Copy link
Collaborator

Thanks for the report and for including the ad tag. A fix (to resume content immediately) is in review.

ojw28 pushed a commit that referenced this issue Sep 7, 2020
Issue: #7832
PiperOrigin-RevId: 329497598
@ojw28 ojw28 closed this as completed Sep 12, 2020
@chladto1
Copy link
Author

chladto1 commented Oct 18, 2020

Unfortunately, here you are another test content that leads into stuck media playback. Can you please take a look?

VPAID in preroll, 3 ad breaks and postroll
Test content: https://devs.origin.cdn.cra.cz/ima/vpaidvmap2.xml
Log: vpaidvmap2.txt

Preroll with ad and VPAID
Test content: https://devs.origin.cdn.cra.cz/ima/vmap2adswithvpaid.xml
Log: vmap2adswithvpaid.txt

ExoPlayer version 2.12.0

@andrewlewis andrewlewis reopened this Oct 18, 2020
@andrewlewis
Copy link
Collaborator

For the first ad tag, I have a change in review that makes the previous the fix referenced above more general, which avoids playback getting stuck. This issue will be updated if/when that's merged.

For the second ad tag, something strange is going on where we are reporting an ad position to the IMA SDK, but the IMA SDK is not updating the ad overlay view, nor notifying us when the ad finishes. I couldn't reach any conclusions about the cause of this I'm afraid. Given that VPAID ads are officially listed as unsupported here, I don't think we should spend a lot of time diagnosing what's going on with the second tag and finding a way to make it fail gracefully. I think the best way to address this is to configure your ad server not to serve VPAID ads to Android clients.

@BucherTomas
Copy link

@andrewlewis Thank you for looking into it.

I agree that VPAID ads should not be even served to mobile devices in ideal world. However, ad servers often utilize their own rules serving ads and even though ad campaigns on these servers are managed by people owning applications that use ExoPlayer, they might not have the means to affect the ad server logic and filter out VPAID ads from ad pool targeted at mobile devices.

That is why the purpose of this ticket is to make ExoPlayer + IMA combo as robust as possible when handling VPAID ads since player stalling as a result of failure is fairly bad UX.

If you believe that IMA is doing something wrong, would you be so kind and forward it to them together with your findings? Thank you.

ojw28 pushed a commit that referenced this issue Nov 2, 2020
Issue: #7832
PiperOrigin-RevId: 339087555
icbaker pushed a commit that referenced this issue Nov 30, 2020
Issue: #7832
PiperOrigin-RevId: 339087555
@andrewlewis
Copy link
Collaborator

I need to revert this workaround as it caused the regression reported in #8428 but I plan to replace it with a different workaround that allows loading the VPAID ad to time out.

kim-vde pushed a commit that referenced this issue Jan 22, 2021
The IMA SDK currently notifies `CONTENT_RESUME_REQUESTED` then
`CONTENT_PAUSE_REQUESTED` quickly afterwards when playing an ad for an initial
seek. This triggered the logic to skip VPAID ads added for Issue: #7832,
causing the ad to be skipped.

This change reverts the fix for that issue and extends the ad preload timeout
logic to cover the case of an initial seek as well. Incompatible VPAID ads will
still be skipped but only after the preload delay (this seems fine given that
they are documented not to be supported, and we are just making the failure
mode less bad on a best-effort basis!).

Issue: #8428
Issue: #7832
PiperOrigin-RevId: 353011270
@google google locked and limited conversation to collaborators Apr 3, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

5 participants