Daverz;619120 Wrote:
> I wonder if an external scanner might be the way to go. I wrote a
> Python script that dumps all the tags to an easily parsed text file,
> and this only takes about 20 minutes to scan everything. Perhaps a
> plugin could then read and process the text file? Or does the data
> discovery have to be integrated in order to pick up certain SBS
> specific info?
>
How long does Custom Scan take for the same library ?
I think the information needs to be stored in the database but if it's
faster for the plugin to read a text file and import that into the
database that might be a solution.
The CustomScan plugin actually have an API so it's possible to
implement scanning modules as separate plugins. So if you like to try
implementing something that reads your text file and hooks into Custom
Scan, you can do that already today.
You basically have to implement a plugin that provides a function
"getCustomScanFunctions". It will return a description of the scanning
module and references to a scanning function you implement which will
be called for each track. The scanning function you provide will be
called with a track object from which you can get the path or url and
based on that you need to be able to return the tags from your text
file.
If you are interesting in trying something like this, let me know and I
can provide you with a simple sample plugin to start from.
I suspect the performance issues in Custom Scan is generally related to
a number of things:
1.
It always performs a full rescan even if you do an new/changed scan in
SBS
2.
If you have the "Use raw MP3 tags" option checked in Custom Tag
scanning module it reads the file twice, this probably isn't an issue
since it's in the file system cache, but I haven't investigated it.
3.
It can't be executed in a separate process as the standard scanner, due
to this it needs to give other functions some room instead of trying to
scan as fast as possible. This will be possible to solve in 7.6 with
the new scanner API.
4.
All tags are stored in a single table which is indexed for read
performance but this probably result in slower write performance during
scanning. This can probably be optimized a lot by someone that knows how
to index a database for best performance.
--
erland
Erland Isaksson ('My homepage' (http://erland.isaksson.info))
(Developer of 'many plugins/applets'
(http://wiki.slimdevices.com/index.php/User:Erland). If my answer
helped you and you like to encourage future presence on this forum
and/or third party plugin/applet development, 'donations are always
appreciated' (http://erland.isaksson.info/donate))
------------------------------------------------------------------------
erland's Profile: http://forums.slimdevices.com/member.php?userid=3124
View this thread: http://forums.slimdevices.com/showthread.php?t=85180
_______________________________________________
plugins mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/plugins