|
MultiThreading
Using the Multi-Threading Parameters to speed up MovieJukebox
Featured, Restrict-AddWikiComment-Commit, Multi-Thread IntroductionWith v1.6 of MovieJukebox, Multi-Threading has been introduced to enhance the speed of MovieJukebox. This page will attempt to explain what multi-threading does and how you can tweak it to your set-up. MovieJukebox PerformanceLet's be clear about where the perceived performance of MovieJukebox can be improved:
It's a function of how long it takes to scan the locations for the information over the network and the latencies involved. Where does Multi-threading help?Multi-threading speeds up #3 (mjb.MaxThreadsScan) & #4 (mjb.MaxThreadsProcess). These are often the longest/slowest parts of the run, certainly #3 is for existing jukeboxes and #4 for new jukeboxes. mjb.MaxThreadsScanSetting mjb.MaxThreadsScan > 1 means that there are that many threads running in parallel searching your library at the same time. How many should you use?This largely depends on your set-up and PC/Mac capability. If you have a low bandwidth wireless connection, you probably wont see much benefit beyond 5. If you have local video files and a modern PC, 15 would probably work fine. Unfortunately it's a trial and error approach. mjb.MaxThreadsProcessSetting mjb.MaxThreadsProcess (in conjunction with some other parameters detailed below) is what limits the downloads threads for specific sites. So, as the scanning threads are requesting downloads they are put in a "queue" for the processing threads to download. The scanning threads then wait for the processing threads to finish before continuing their scan, so there is no point making this setting more than the mjb.MaxThreadsScan setting. Just because you set this property to 10 or so, doesn't mean that you will download 10 times as fast, it means that there are 10 download slots for the scanning threads to use, and these can be further restricted by the sites that they are pulling from. For example, TheTVDB and TheMovieDB are set to 2 each, meaning that even if there are 10 threads requesting downloads, only 2 will be processed at any one time for each of these sites (see below). This is to prevent us overloading these sites with download requests. Why don't I just set this to 2 then? Well, you might get the situation where you are downloading 2 threads from TheTVDB.com, 2 from TheMovieDB.com, 5 from IMDB and 1 from google: And that's where the speed increase will come from. Limiting Downloads Per SiteTo be completed... |