Ad events (AD_START, AD_BREAK, AD_STOP..etc) is not fired with Google DAI + DASH
Like I said in the title, When I tried Google DAI + DASH, everything seemed fine, but Ad events (AD_START, AD_BREAK, AD_STOP..etc) were not fired. Ad events work fine when I use Google DAI + HLS. So the question here is Google DAI + DASH is still not fully supported or is this a bug?
It's a bit unclear what you are doing from your report.
I assume with Google DAI you are referring to ImaServerSideAdInsertionMediaSource for which you register an AdEventListener.
The ad event listener is from the SDK and the ExoPlayer extension does not intercept any ad events. The listener is registered on the stream manager after the assetKey or contentId is resolved by the SDK.
If you don't get events,. then the SDK is not sending them.
When you use the SDK directly, do you see these events for DASH?
If you are indeed using ImaServerSideAdInsertionMediaSource, then you can listen to player events also. You see a Listener.onPositionDiscontinuity() when each period starts and aned. This is true for ad periods in the same way and you can get the information about which ad is currently being played from the PositionInfo that gives you adGroupIndex and adIndexInAdGroup as well as the position of the discontinuity in the stream.
If this isn't sufficient for you and you want the SDK events, then we can't help unless you see these events when using the SDK directly which isn't really likely because we do not intercept any events coming from the SDK.
@marcbaechinger Thank you, I will discuss with my team about creating a content for testing. But before that, is there any solution that can avoid that error? At least it won't cause the app to crash ?
At least it won't cause the app to crash ?
You didn't report a crash but events that are not fired, right? Can you clarify with a stack trace or better a bug report?
Like I said above, the SDK is not firing these event, but I don't think the extension is expecting them. I'm not aware of a crash unless you expand on that a bit.
@marcbaechinger I'm so sorry about this. I commented on wrong thread. The correct is here. Sorry for my mistake https://github.com/androidx/media/issues/1520#issuecomment-2221800339