missing index for deleting outdated session data in fe_session_data
in class.tslib_feuserrauth.php:fetchSessionData() is a query to delete outdated data, with a WHERE condition on `tstamp` which has no index - at least for the system i am observing right now - this takes 1.3 seconds on average (executed 10k times on 24h) - way too long
is there any reason why there is no index on `tstamp`?
(issue imported from #M9289)
Updated by Saverio Vigni almost 13 years ago
I've found the same problem while trying to optimize the performance of a new website i'm working on, fe_session_data was getting quite large ( > 20000 records) and the start of the garbage collector was causing a major load on the mysqld process.
Setting an index to the timestamp field brought back the load to more resonable levels, for the moment everything seems working fine, but i would suggest to add that index, i don't know any reason why isn't there.