User tests: Successful: Unsuccessful:
Smart Search module creates new Query and triggers Joomla\Component\Finder\Administrator\Indexer::processString()
method which loads available taxonomy branch titles via separate SQL query per each module (duplicate query).
We should not process empty string, when the module is loaded without any input. Plus, Taxonomy::getBranchTitles()
load should use static cache and produce only single query to prevent duplicate when we have multiple mod_finder instances (i.e. typical case for Yootheme templates where one module is rendered in header and second in mobile dialog).
Create two Smart Search modules, apply patch,
Load page with Smart Search modules, see duplicate queries like:
SELECT `title`
FROM `jos_finder_taxonomy`
WHERE `parent_id` = 1 AND `state` = 1 AND `access` IN (1,5)
No useless queries, the mod_finder render time is also faster now.
Status | New | ⇒ | Pending |
Category | ⇒ | Administration com_finder |
Labels |
Added:
PR-5.3-dev
|
Title |
|
I have tested this item ✅ successfully on 7826570
I see the number of queries decrease by 2 on both the pages with two modules and the results page with a side module. No problems observed.
This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45347.