Bug 6420 - Browse Music Folder takes 10-15 seconds
: Browse Music Folder takes 10-15 seconds
Status: RESOLVED WONTFIX
Product: Logitech Media Server
Classification: Unclassified
Component: Database
: 7.0
: PC Debian Linux
: P2 normal with 2 votes (vote)
: Future
Assigned To: Unassigned bug - please assign me!
http://forums.slimdevices.com/showthr...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-12-20 00:15 UTC by Me
Modified: 2011-01-24 00:14 UTC (History)
1 user (show)

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Me 2007-12-20 00:15:38 UTC
When selecting "Browse Music Folder" in the web interface, I have to wait 10-15 seconds to get a result.   This delay is not present in the Squeezebox player interface.   

The database seems fast enough:
  mysql> select title, url from tracks where content_type = 'dir' order by title limit 250 offset 250;
  (...)
  250 rows in set (0.14 sec)

Disk I/O should be OK as well, I get about 80mbps when copying from one USB2 drive to another.

According to andyg (http://forums.slimdevices.com/showpost.php?p=250236&postcount=41) this might be because one query is done for each entry.  This is related to bug #1360 which needs this to ignore files referenced in cue sheets, as well as to look for artwork.  One query per entry seems like an awful waste, and could probably be optimized a lot.  As an intermediate fix, one should be able to turn off these extra queries.

My setup:
- 500 MHz Debian box with 256 MB ram
- Music collection on local USB2 hard drive
- Browse folder setting: 250 items per page
- The music collection has about 3000 albums with 30000 songs
- Collection is organized as artist/album/song
Comment 1 KDF 2007-12-20 02:13:37 UTC
it is also because users have repeated requested ways to have the database updated without scans.   This has meant BMF does the work, checking for new/missing info and filling in the metadata. can't have both worlds unfortunately.  The pendulum swinging is getting very tired.
Comment 2 Andy Grundman 2007-12-20 05:42:44 UTC
Reduce your items per page to 50.  This is not a bug, but a feature, as kdf said.
Comment 3 Me 2007-12-20 06:47:49 UTC
I don't quite agree.  I have about 1000 artists in my music collection.  If I lower the items per page to 50, it is almost impossible to navigate to a given artist.   This is due to the plain pager that uses numbers instead of artist initials:  is Elvis on page 3 or 10?

One can argue that the pager should be changed, but that is another issue.  I still believe that the browse folder functionality should be implemented with performance in mind.
Comment 4 Andy Grundman 2007-12-20 06:52:26 UTC
Why don't you use the Artists menu instead?
Comment 5 Me 2007-12-20 07:01:15 UTC
> Why don't you use the Artists menu instead?

The Browse Folder feature is unique in that it uses the folder structure to navigate in.  My collection has a well-maintained folder structure, which makes this method the preferred one.

The other navigation features (such as the Artists menu) are based on tags (or guessed tags, I presume?).  Although most of my music has correct tags, the last 10% of the collection has missing, bad or incorrect tags.  This makes tag-based navigation fairly messy.
Comment 6 Andy Grundman 2007-12-20 07:06:22 UTC
If you want the best performance, fix your tags and use the Artists menu.
Comment 7 Me 2007-12-20 07:49:25 UTC
That is, of course, the ideal solution.  In my case, where the 10% of badly tagged music equals about 3000 songs, that's not easily done.  I would think that I'm not the only one in this situation.  (On the other hand I, maybe I am?)
Comment 8 Andy Grundman 2007-12-20 07:56:46 UTC
I will recommend MusicBrainz, it will probably help you properly tag a good portion of those 3000 songs.
Comment 9 Blackketter Dean 2007-12-28 05:45:26 UTC
Sounds like a tagging problem.
Comment 10 Me 2008-01-11 01:30:03 UTC
> Sounds like a tagging problem.

But the whole point of "Music Folder" is to display the music folder content *regardless* of the tagging, isn't it?  I still believe this is a bug, or at least something to be considered as a performance backlog issue.
Comment 11 KDF 2008-01-11 09:43:27 UTC
I'll say again, (In reply to comment #10)
> > Sounds like a tagging problem.
> 
> But the whole point of "Music Folder" is to d

give users the option of displaying using their own folder structure AND
to give access to scanning subsections of their library when there is new metadata

Sorry, but we've gone back and forth over this too many times.  This is the way it works 
and we realise that there are sacrifices that had to be made for the desired function.

The choice is yours.
Comment 12 Eugene Dugaev 2008-01-23 11:24:21 UTC
I'm not the owner of the bug, but it concerns me as well. 
Ok, the behaviour and purpose of BMF is clear to me: it allows rescanning certain parts of the lib.

However, such scanning sometimes (not always, but often) seems to pause playing audio. Here's how it's reproduced:
- browse music folder, choose folder with album, press "play" to play the album folder (contains 10-12 tracks)
- first track starts playing but after a while it stops and trasnporter doesn't respond to remote, stays like that 1-5 seconds
The rest of the album is played with no problem

Please let me know which log to turn on, so that I could post log details.

I have core duo intel macbook with SC7 (wireless g connection), external nfs fileserver with music (wired ethernet connection) and transporter (wired ethernet connection.

I am posting this, as it wasn't an issue with previous versions of Squeeze Center.

Comment 13 Alan Young 2011-01-24 00:14:19 UTC
BMF is a back door to permit user initiated partial rescans. It has an inevitable performance hit. It is not intended to be used as a primary library navigation mechanism.