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

Speed up time-to-first-enqueue #78

Open
joshkunz opened this issue Jul 22, 2020 · 2 comments
Open

Speed up time-to-first-enqueue #78

joshkunz opened this issue Jul 22, 2020 · 2 comments

Comments

@joshkunz
Copy link
Owner

Right now, we performance test ashuffle startup (time to first enqueue) at <750ms for a 20k track library. This is still surprisingly slow. We should try and improve this.

I think a reasonable target would be <200ms startup with a 100k track library. That should be fast enough that the user never notices ashuffle startup.

@hindumagic
Copy link

Hi, just an idea..
I don't know how ashuffle specifically works, but I assume that it performs a listallinfo on startup for every execution. One approach would be to save down that info and only do a check on startup if there is new info (like total number of tracks changed or if mpd has a mechanism for this).

@joshkunz
Copy link
Owner Author

That's not a bad idea. It could probably key off of the db_update field of the stats command. A big question for me, is how it would interact with filters. I'm not totally sure of the timing breakdown at startup, but it seems like we'd probably want to cache the filtered song set (the loaded "shuffle chain") which would depend on the filters passed at startup.

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

No branches or pull requests

2 participants