Bugzilla – Bug 1153
Don't run intensive tasks while music is playing.
Last modified: 2009-09-08 09:13:49 UTC
For compute intensive tasks, such as the db cleanup sweep - since we control the horizontal and the vertical, don't run those when music is playing. Enter the function occasionally, and keep track of - ok, I've not played any music in the past 15 minutes, it's ok to run now. And back off when music starts up again. The same can apply to the Rescan plugin, as well as iTunes auto-scanning.
What's the actual problem here? Is it that the music breaks up? Or the UI is unresponsive? It's not clear from the description what the bug is, rather specifies an optimization before we know what we're optimizing for.
Dropouts - that's always the problem. Bad for SB1/SliMP3 users. Not so bad (may not exist) for SB2 Users. Bad in general on slower machines. IMO, spiking the CPU when we're playing music can cause issues.
Ok, let's understand the specific issues and fix them. The "intensive" tasks shouldn't be blocking for seconds. Background scanning shouldn't be an intensive task, nor should iTunes importing...
The iTunes problem is the playlists. Processing them uses 100% CPU on my 2Ghz P4. Results in TOTAL loss of connection to clients. I guess parsing the playlists is so simple (it's just a lookup in a hash I think?) that it can really churn the CPU.
James: That sounds like a separate bug. Total disconnections shouldn't happen at all. Can you file another bug with details and attach a compressed copy of your iTunes Music Library.xml file? Thanks.
Maybe I used the wrong wording; When the iTunes playlists start scanning (note not the files/library) the display stops, then the music stops and I get the 'lost connection with SlimServer' message. When the rescan completes the clients reconnect immediately, not going through the setup screens.
That definitely shouldn't happen (and the disconnection problem would happen even if you weren't playing music.) Please do file a separate bug with details and your XML file. thanks.
On my SB2, when SlimServer is running a 100% task such as a rescan, there is no problem with the music, but the scrolling and IR response time is severely impacted. There is a lag of several seconds when using the remote, and scrolling text becomes jerky. Maybe these processes could be throttled to run slower if any player is currently active.
Would like some profiling to find out which section of the scan code is blocking for too long.
This is part of the split-scanner changes.
Marking this as closed - trunk now includes the forked scanner. If there are other bugs, please create them with more specific wording. Thanks