Bug 232976

Summary: Store dynamic Collections in database - don't scan them on every mount
Product: [Applications] amarok Reporter: andre.wittmann
Component: Collections/Media DevicesAssignee: Amarok Developers <amarok-bugs-dist>
Severity: wishlist CC: aumuell, devurandom, dextpol, jon, matej, pndiku
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Gentoo Packages   
OS: Linux   
Latest Commit: Version Fixed In:

Description andre.wittmann 2010-04-01 16:38:22 UTC
Version:            (using KDE 4.4.1)
OS:                Linux
Installed from:    Gentoo Packages

I have a small collection on the internal drive of my notebook and a lager one on a external drive (scanning the external one takes about 30min).
The internal collection is added to amarok as "Local Collection" and the one on the external drive is recogniced as seperate one every time i mount the drive.
Merging both collection into one big is no solution as i would have 99% dead files when the external one isn't mounted.
But like amarok behave at the Moment, it completely scans the external drive everytime I mount it and doesn't store it into it's database. As the external collection is very big and does only change 1-2 times a month this is a very inefficient behaviour and it would be better if you can tell amarok when it should re-scan the drive..
Comment 1 Sven Krohlas 2010-04-02 11:45:54 UTC
The long term idea is to store the database of a media device on the device itself. But I have no idea when that will be ready.
Comment 2 Jon Skanes 2010-04-03 20:18:43 UTC
I, too, would love to see this feature.  I'm in the same situation having most of my media on an external drive.  Having to wait tens of minutes to access it each time I reconnect the drive ruins the usability of an otherwise wonderful music player.
Comment 3 Daniel Krysiak 2010-04-07 19:35:30 UTC
I've got 161GB, ~15.000 files, but on server (over NFS). Every time, I lost connection (for example after suspend) Amarok scans everything again - it takes about 60-90 minutes. It was worst, when I keep data base on server using MySQL...
Comment 4 Peter C. Ndikuwera 2011-03-03 16:23:57 UTC
Git commit d57eedc5563b3950446257f09d439aaa3b8c21ee by Peter C. Ndikuwera.
Committed on 03/03/2011 at 16:01.
Pushed by pndiku into branch 'master'.

Fix NFS & SMB/CIFS Remote collection

BUG: 249760
CCBUG: 232976
CCBUG: 171213
CCBUG: 187692

Using Max's Mass Storage Device code as a guide, this commit returns
network-based collections, shared over NFS & SMB/CIFS to the dynamic
collection architecture.

This should re-validate http://amarok.kde.org/wiki/Dynamic_Collection,
which some people have complained to longer applies.

Test it & break it!

M  +3    -3    src/core-impl/collections/db/sql/MountPointManager.cpp     
M  +2    -2    src/core-impl/collections/db/sql/device/CMakeLists.txt     
M  +14   -6    src/core-impl/collections/db/sql/device/nfs/CMakeLists.txt     
M  +77   -30   src/core-impl/collections/db/sql/device/nfs/NfsDeviceHandler.cpp     
M  +12   -8    src/core-impl/collections/db/sql/device/nfs/NfsDeviceHandler.h     
M  +14   -6    src/core-impl/collections/db/sql/device/smb/CMakeLists.txt     
M  +76   -32   src/core-impl/collections/db/sql/device/smb/SmbDeviceHandler.cpp     
M  +11   -7    src/core-impl/collections/db/sql/device/smb/SmbDeviceHandler.h     

Comment 5 Peter C. Ndikuwera 2011-03-03 16:27:08 UTC
a fix for remote NFS collections so they don't get rescanned.

For the user with a large external drive, what I do is I actually select the
drive as part of the collection (in the "Settings|Configure Amarok|Collection"

With dynamic collections, the files on this drive will be disabled whenever the
USB drive is disconnected.
Comment 6 Matěj Laitl 2012-02-05 21:18:17 UTC
I guess this is fixed by now, bug 293277 corrected gui strings so it should now be more clear that "Dynamic Collection" is all about Local Collection.

*** This bug has been marked as a duplicate of bug 93277 ***
Comment 7 Matěj Laitl 2012-02-05 21:19:15 UTC

*** This bug has been marked as a duplicate of bug 293277 ***