Low Search in MySQL 5.7
Hi Low,
I've got an old website that's running EE 2.11.2 and Low Search 4.4.4.
I'm trying to move the site from a cPanel VPS that runs MySQL 5.6, to a new cPanel VPS (with more RAM so it should be faster) that happens to run with MySQL 5.7.
Everything else is setup the same and this is using PHP 5.4. I'm just testing the site and noticed that everything seems okay, except that performing a search with a Low Search form is taking about 7 seconds on this new VPS, but it was only taking about 1.5 seconds on the old VPS.
The only difference I can see is that this new VPS is using MySQL 5.7 instead of 5.6, but I'm told it can't be downgraded easily.
Do you have any idea why Low Search might seem to work a lot slower in MySQL 5.7?
Looking at the template debugging, it seems to slow down a lot after the 'Low Search: Calling the channel module' line. If I disable whatever extensions are listed after that, it doesn't really make any difference and whatever follows 'Low Search: Calling the channel module' is taking over 3 seconds (which is a large chunk of this extra time).
(0.221607 / 23.93MB) Low Search: Pre-applying search vars to tagdata
(0.231355 / 24.14MB) Low Search: Calling the channel module
(3.521634 / 26.05MB) Calling Extension Class/Method: Low_reorder_ext/channel_entries_query_result
Do you have any idea why Low Search might seem to work a lot slower in MySQL 5.7?
Thanks for any advice,
Stephen
Replies
Low 11 Jul 2018 14:16
It might look like a LS issue, but the time gap between those to log entries is practically all native workings.
Low Search uses the native Channel Entries tag to generate the search results. When LS says 'Calling the channel module', it has done most of the work, set the fixed_order or entry_id parameters, and calls channel:entries to let it parse the entries. That's where it takes a lot of time, but LS is pretty much done by then (apart from some minor post-processing).
So, not a lot LS can do here.
Stephen 11 Jul 2018 16:07
Hi Low,
No worries, thanks for letting me know.
Thanks,
Stephen
Paul Cripps 5 Feb 2019 15:57
@stephen, did you manage to make speed improvements?