-
Notifications
You must be signed in to change notification settings - Fork 413
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
[CMCD] Too many buffer starvation reports #1124
Comments
Hi @mikef-dk, The behavior is actually working as intended. CMCD data is reported whenever a request is made to get a chunk. When starvation occurs, there are actually two requests made to fetch chunks i.e. one for audio and the other for video. If you observe closely, CMCD data reported also contains a field called |
Hi @rohitjoins, thanks for looking into this and your explanation. Maybe my "expectation" as outlined in the issue description was a bit misleading: In fact I would expect 0 "buffer starvations". If the media didn't even start - so not a single chunk has been loaded before because it's the initial loading - why would you consider this as a "buffer starvation"? There was never any data in the buffer before. By doing this basically every stream would report 1-2 buffer starvations leading to faulty reports. As an additional note: Afaik, Shaka Player doesn't have this "issue" - they don't report any buffer starvation during the initial setup/loading. |
The buffer starvation is not reported before the initial loading. If you log the |
@rohitjoins I don't see any buffering Icon and the
There is no additional transition to I've also added logs to the
Before the first CMCD report we apparently already have 7 seconds of buffer. Do I interpret the data wrong? |
Thanks for the detailed info. I'll debug this further to reach a conclusion and will keep you posted. |
Are there any updates on this? For us, the CMCD data is useless without the correct buffer starvations. |
Hi @totallyunknown, I'm working on this and will soon provide a fix for this. |
The last rebuffer time was being updated erroneously, even in the absence of rebuffering events, resulting in incorrect `bs` (buffer starvation) key in CMCD. Issue: #1124 PiperOrigin-RevId: 629731796
A fix has been submitted to the |
@rohitjoins Thanks for the fix - really appreciate it. 🙏 Will there be another 1.3.x release with this fix or is it only coming to the 1.4.0 version that is currently in alpha? |
@mikef-dk, I believe there won't be any further bug fix releases. The fix will be included in any new release related to version 1.4.0. |
Version
Media3 1.2.1
More version details
No response
Devices that reproduce the issue
Reproducible on any device
Devices that do not reproduce the issue
No response
Reproducible in the demo app?
Yes
Reproduction steps
Prerequisite: Add
CmcdConfiguration.Factory.DEFAULT
toDefaultMediaSourceFactory
inPlayerActivity
and optionally logs toLoadingInfo#rebufferedSince
Expected result
One Buffer Starvation (bs) event in the CMCD data (video needs to load therefore I would expect only one)
Actual result
Two Buffer Starvation (bs) CMCD events are reported
Looking at the logs I can see that
rebufferedSince
was called twice:1st time: realtimeMs = 299910722
2nd time: realtimeMs = 299910780
In both cases the
lastRebufferRealtimeMs
was299911159
so the method returnedtrue
. So in the end two buffer starvations are reported but in fact only one rebuffering happened.Media
UHD (cbcs)
HD (cbcs)
Bug Report
adb bugreport
to [email protected] after filing this issue.The text was updated successfully, but these errors were encountered: