Home User Forums SongKong Music Tagger Jaikoz Music Tagger Albunack Music Service

Friday, 21 June 2019

SongKong 6.2 Hunkpapa - Performance Release released on 20th June 2019

We are pleased to announce the new release of SongKong, SongKong 6.2 Hunkpapa named after the third album by Throwing Muses released in 1989. This is a really fantastic album, with some great tracks from both Kirstin Hersh and Tanya Donelly. 


Better Performance

In this new release we have made many changes to improve performance, these fall into two categories database and concurrency. This is quite a technical blog post but I thought some of you may find it interesting.


Better Database Performance

SongKong stores your music metadata in a database, this means we can:
- Provide an Undo feature
- Quicker reloading of files instead of having to access fileystem
- Minimal Data stored in memory so SongKong is scalable huge music collections. 

SongKong uses Hibernate on top of the H2 database. Hibernate provides a useful abstraction from the database, but it can lead to inefficient database querying. We have now gone through all queries and made a number of performance improvements to reduce the database load.

We have moved from H2 1.3 to H2 1.4, this is not a minor change. H2 1.4 uses a completely different database format for greatly improved performance.


Concurrency

SongKong is a multi-threaded application, this means there can be more than one thread of activity going on at the same time. The key threads that do most of the work are called the worker threads. 

By default the number of worker threads matches the number of cpus of the computer so we can utilize all cpus

If the computer has only one cpu we still have at least three worker threads. This is because SongKong gets much of its data from the internet so once a request is made to the Internet it just waits for the results, so no cpu is being used. If we have multiple threads than the cpu can service a different request whilst waiting for results.

In this release we have made improvements to how the concurrency works. This will see most improvements on single cpu systems and conversely also high end systems with more than 16 cpus.

Optimization, Control Worker Threads


To reiterate, by default the number of worker threads matches the number of cpus of the computer so we can utilize all cpus, with a minimum value of three.

If customers are running SongKong on a whole collection it is usually recommended it is run overnight. But if you want to limit the number of worker threads because you are actively using the computer at the same time for other work then now you can.

Just modify your general.properties file and add a line workers=n where n is number of worker threads.

i.e.

workers=4

Then when you start a task it will only use that amount of worker threads, you can check this by looking at your songkong_user0.0.log file

When you start a task it should say

21/06/2019 09.30.19:BST:SEVERE: Workers Configuration:4

We have a number of other fixes, and the full list can be found here

No comments:

Jthink blog Jthink Facebook page google_plus Jthink YouTube channel Email Paul at Jthink Subscribe to Weekly Newsletter