Posts: 234
Joined: Nov 2009
Reputation:
4
I solved this problem by moving to a smart-playlist friendly skin. Arctic zephyr to be precise.
This skin makes it very easy to create smart playlists that you can apply as widget. In these smart playlists which you can basically change the mysql query. This way i limited it to 10 results which gives lightning fast results.
Posts: 1
Joined: Nov 2016
Reputation:
0
I'm afraid you are looking in the wrong place. You can do all you want to make MySQL faster, but it is not going to solve anything. I have a low spec MySQL server (Basic QNAP fileserver), and I use a Raspberry PI as Kodi client using MySQL. I added a smart playlist with 'afrikaans' in the Genre. Once the smart playlist was created, I pressed 'q' to while the playlist title was selected. It took between 20 and 30 minutes (not SECONDS - MINUTES) before the first song started playing. Enough time for me to log into Kodi Raspberry PI via ssh and to see what was going on. The processor was running at about 2.5% and kodi was only using 19% of RAM - in other words it was idling all the way. So I installed a MySQL client (command line) on the RPI. To get a list of the songs I was looking for could be retrieved with a simple SQL statement, so I executed "SELECT * FROM song WHERE lower(strGenres) LIKE '%afrikaans%'. 0.7seconds (Yes - less than 1 second) later I had information of all of the 1081 songs transferred to my Kodi RPI via my GB LAN connection. All this basically means is that whoever wrote the MySQL interface (or the framework for getting playlist information for that matter) basically does not know anything about programming. If it was developed properly you would have had your playlist ready and sorted in the sequence you preferred in less than 2 seconds. Ok, so there is a bad design in Kodi, but even with that there are ways to have kodi perform as if the playlist was always immediate. If you have a song, start playing it (in stead of locking the entire frontend - yet another BAD design - threads allows a good programmer to have a responsive frontend while some heavy lifting is happening where no one is aware of it) - there is no point in waiting till you have all 1000 items loaded if you tortoises are laughing at you. If you get the first song, PLAY it. If you managed to load another 20 songs by the time song 1 is at its end, then make a better decision on which one to play next. But really - the infrastructure needs attention!!!!
Posts: 16,946
Joined: Feb 2011
Reputation:
256
Finally someone who realised that kodi was created by a bunch of internetional idiots. There is light at the end of the tunnel now that we will see some proper, sane and obvious correct performance fixes from our new and first "real good programmer" named stellenbosser. Its so good to have you on board. Looking forward to finally learn something from you.
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much:
click here
HowTo setup NFS for Kodi:
NFS (wiki)
HowTo configure avahi (zeroconf):
Avahi_Zeroconf (wiki)
READ THE IOS FAQ!:
iOS FAQ (wiki)