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

Excessive Mopidy API calls while buffering #237

Closed
kingosticks opened this issue Apr 1, 2017 · 1 comment
Closed

Excessive Mopidy API calls while buffering #237

kingosticks opened this issue Apr 1, 2017 · 1 comment

Comments

@kingosticks
Copy link
Member

kingosticks commented Apr 1, 2017

When starting to play a radio station the webclient appears to hammer Mopidy with get_time_position calls while it's buffering. In the log you can see Mopidy doesn't do anything after 19:41:02,520 until 19:41:10,151 when buffering completes, except respond to our numerous requests.

This was observed in Mopidy v1.x (Musicbox v0.7.0RC4) so it's possible it's related to some old bug there, I do need to reproduce this in the latest Mopidy.

Log here

@jcass77
Copy link
Member

jcass77 commented Apr 14, 2017

This is related to mopidy/mopidy#1420: at the moment, there is no easy way to tell whether a stream is still busy buffering, or if it has actually started to play.

We won't be able to eliminate superfluous get_time_position calls entirely until the Mopidy core is enhanced to provide audio events that are a little more verbose, instead of having to rely exclusively on playbackStateChanged.

Having said that, it should be possible to at least reduce the rate at which get_time_position is called to something more sensible (i.e. once every 500ms or so).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants