home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
MediaPortal 2
Plugin Development
SQLiteDatabase Plugin for MP2
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="MJGraf" data-source="post: 1035366" data-attributes="member: 17886"><p>Hi breese,</p><p></p><p>there will be a test version of the next SQLiteDatabase plugin version soon. I'm currently waiting for system.data.sqlite v1.0.89.0 to be released (see here), which is scheduled for October so it shouldn't be too long anymore. The main reason for waiting is that this release of system.data.sqlite will include the SQlite native <a href="http://www.sqlite.org/releaselog/3_8_1.html" target="_blank">version 3.8.1</a>, which was release on October 17.</p><p>Currently we use system.data.sqlite version 1.0.88.0, which only includes SQLite native version 3.7.17.</p><p>Starting with version 3.8.0 (and therefore also contained in v3.8.1) of SQLite native there is a completely new query optimizer included, which is said to give a material speed improvement for read queries.</p><p>I'm curious how this will affect our SQLiteDatabase plugin speed in MP2 <img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite1" alt=":)" title="Smile :)" loading="lazy" data-shortname=":)" /></p><p></p><p>As to your test results (thanks again for all your efforts, this is very interesting and helpful):</p><p>Somehow I get the feeling that something is wrong - but I cannot say, yet, what and why. Let's take a look at the relevant parts of the log files:</p><p></p><p><u><strong>Raid5/SSD:</strong></u></p><p><u>SQLite:</u></p><p></p><p>==> 6 seconds</p><p>==> Database file size: 1.272KB</p><p></p><p><u>SQLCE:</u></p><p></p><p>There is no log entry between 9:58:56 and 10:09:28</p><p>==> 632 seconds</p><p>==> Database file size: 1.664KB</p><p></p><p></p><p><u><strong>Ramdisk/Ramdisk:</strong></u></p><p><u>SQLite:</u></p><p></p><p>==> 8 seconds</p><p>==> Database file size: 1.272KB</p><p></p><p><u>SQLCE:</u></p><p></p><p>==> 0.5 seconds</p><p>==> Database file size: 1.664KB</p><p></p><p>First of all, the database file sizes are identical for SQLite Raid5/SSD and SQLite Ramdisk/Ramdisk. Same applies to SQLCE. That means that in both cases both databases import the same amount of data. Just as it should be.</p><p>The database file size is in both cases somewhere between 1MB and 2MB. When the folder name of your share is correct, you import 500 music files so I would assume that there are no covers imported, because otherwise the database file size would be too small.</p><p></p><p>Now when the music files are located on your Raid5 and the database is located on SSD, the import with SQLite takes 6 seconds, the same import with SQLCE takes 632 seconds. I should be very happy with that result and I wouldn't exclude that it is correct. But on the other hand, a speed improvement of more than 100x as fast for the import would really be amazing. I'm so surprised about it that I still have my doubts whether there may be just a bug in SQLCE that makes it so slow...</p><p>Taking into account that the database file size in the end is only 1.2MB, I would consider 6 seconds as normal - most of the time is probably spent for reading the tags from the files, because SQLite can hold the database with a size of < 2MB completely in its cache, so database access itself should be very fast.</p><p></p><p>In case both, the music files and the database are located on your RamDisk, the whole thing starts to become really strange. Now all of a sudden SQLCE only needs 0.5 seconds instead of 632 seconds, but SQLite takes 16x as long, i.e. 8 seconds. So SQLite is slower with the RamDisk than when using Raid5/SSD. I just can't believe that...</p><p></p><p>But as I said, I don't know yet how we tackle this. Best thing would probably to wait at least for my next test release of SQLiteDatabase. Then I could provide you with an additional MP2 core DLL which includes additional logging. That way we could see exactly how long it takes to read the tags and to write it to the database for every single music file. Maybe this makes it a bit clearer...</p><p></p><p>Thanks again!</p><p>Michael</p></blockquote><p></p>
[QUOTE="MJGraf, post: 1035366, member: 17886"] Hi breese, there will be a test version of the next SQLiteDatabase plugin version soon. I'm currently waiting for system.data.sqlite v1.0.89.0 to be released (see here), which is scheduled for October so it shouldn't be too long anymore. The main reason for waiting is that this release of system.data.sqlite will include the SQlite native [URL='http://www.sqlite.org/releaselog/3_8_1.html']version 3.8.1[/URL], which was release on October 17. Currently we use system.data.sqlite version 1.0.88.0, which only includes SQLite native version 3.7.17. Starting with version 3.8.0 (and therefore also contained in v3.8.1) of SQLite native there is a completely new query optimizer included, which is said to give a material speed improvement for read queries. I'm curious how this will affect our SQLiteDatabase plugin speed in MP2 :) As to your test results (thanks again for all your efforts, this is very interesting and helpful): Somehow I get the feeling that something is wrong - but I cannot say, yet, what and why. Let's take a look at the relevant parts of the log files: [U][B]Raid5/SSD:[/B] SQLite:[/U] ==> 6 seconds ==> Database file size: 1.272KB [U]SQLCE:[/U] There is no log entry between 9:58:56 and 10:09:28 ==> 632 seconds ==> Database file size: 1.664KB [U][B]Ramdisk/Ramdisk:[/B] SQLite:[/U] ==> 8 seconds ==> Database file size: 1.272KB [U]SQLCE:[/U] ==> 0.5 seconds ==> Database file size: 1.664KB First of all, the database file sizes are identical for SQLite Raid5/SSD and SQLite Ramdisk/Ramdisk. Same applies to SQLCE. That means that in both cases both databases import the same amount of data. Just as it should be. The database file size is in both cases somewhere between 1MB and 2MB. When the folder name of your share is correct, you import 500 music files so I would assume that there are no covers imported, because otherwise the database file size would be too small. Now when the music files are located on your Raid5 and the database is located on SSD, the import with SQLite takes 6 seconds, the same import with SQLCE takes 632 seconds. I should be very happy with that result and I wouldn't exclude that it is correct. But on the other hand, a speed improvement of more than 100x as fast for the import would really be amazing. I'm so surprised about it that I still have my doubts whether there may be just a bug in SQLCE that makes it so slow... Taking into account that the database file size in the end is only 1.2MB, I would consider 6 seconds as normal - most of the time is probably spent for reading the tags from the files, because SQLite can hold the database with a size of < 2MB completely in its cache, so database access itself should be very fast. In case both, the music files and the database are located on your RamDisk, the whole thing starts to become really strange. Now all of a sudden SQLCE only needs 0.5 seconds instead of 632 seconds, but SQLite takes 16x as long, i.e. 8 seconds. So SQLite is slower with the RamDisk than when using Raid5/SSD. I just can't believe that... But as I said, I don't know yet how we tackle this. Best thing would probably to wait at least for my next test release of SQLiteDatabase. Then I could provide you with an additional MP2 core DLL which includes additional logging. That way we could see exactly how long it takes to read the tags and to write it to the database for every single music file. Maybe this makes it a bit clearer... Thanks again! Michael [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 2
Plugin Development
SQLiteDatabase Plugin for MP2
Contact us
RSS
Top
Bottom