* Add another SQL index after scanning, which should help UPnPSearch performance on very large containers.

This commit is contained in:
Justin Maggard 2009-04-30 02:31:52 +00:00
parent 7f01aa7080
commit dc2d6cf3ef

View File

@ -845,6 +845,10 @@ start_scanner()
system("/bin/sh /ramfs/.rescan_done");
unlink("/ramfs/.upnp-av_scan");
#endif
/* Create this index after scanning, so it doesn't slow down the scanning process.
* This index is very useful for large libraries used with an XBox360 (or any
* client that uses UPnPSearch on large containers). */
sql_exec(db, "create INDEX IDX_SEARCH_OPT ON OBJECTS(OBJECT_ID, CLASS, DETAIL_ID);");
return 0;
}