Temporary tables

Jeff Mitchell kde-dev at emailgoeshere.com
Fri May 26 16:00:03 UTC 2006


Quoting Maximilian Kossick <mkossick at gmx.de>:

> Hi
> I started to work on an improvement to amarok which is (hopefully) going to
> allow it to handle removable media devices better (e.g. external usb
> harddisks on which you store parts of your collection).

Have you looked at amaroK 1.4?  The Device Manager in it does a lot of  
the kinds of notifications you might want.

> If it works as
> planned, amarok will be able to notice when you connect or disconnect a media
> device which contains parts of your collection and make those parts
> available/unavailable, regardless for the device's mount point.

This sounds somewhat similar to a couple current or past projects.   
One was to make the collection not forget items that it no longer sees  
if the mount points they were on are not mounted.  This way you  
wouldn't have to rescan everything.  I'm not sure this was ever  
finished, but the framework might be in place.  Also, there is a  
project in its infancy about modularizing the collection so various  
sources can be added and removed to and from it dynamically.  Both of  
those are currently being looked at by Andrew Turner, so I'd give him  
a buzz before you go too far.

> I am currently working on CollectionDB and have found out that amarok uses
> temporary tables for something. Unfortunately, i've been unable to figure out
> what it uses the temporary tables for, and so I'm not sure how I have to
> handle them. I searched the forums but didn't find any information there.

The temporary tables are used for incremental collection scanning.   
When incremental scanning is taking place, if a folder is found to  
have been modified (meaning a file in it was modified), that folder's  
files are dropped from the non-temp tables.  Then, scanning is  
performed into the temporary tables.  When the scanning is done, the  
entries in the temporary tables are copied to the permanent ones.   
There are various reasons for doing this, and I'm not the right one to  
explain them, so if you'd like to know why, ask, umm, eean or markey :-)

--Jeff



More information about the Amarok mailing list