-
Thank you, that's really helpful.
The bug happens when the forumId is added, that slows it down. Part of the way I've implemented that must no longer be good, probably since I added the sub-forums stuff. I'll look into it.
It is blindingly fast without the forumId: https://www.lfgss.com/search/?q=%22mks%20gr9%22+sort:date
-
I've got to the bottom of this... it can be summed up as "counting is hard".
The actual search takes less than 2 seconds, but counting how many search results there were takes about a minute. There are only 52 results, but the search has to be fully generated and stored as a temporary table for the count to happen... and that is apparently costly.
I'll need to split up search so that it does the main search as one query, and does the counting as another query. I'll see if I can do it this evening.
Now I don't have the "comments" option at all. I have
Types to display
Filters
Order by