When new content is created, it can take up to one minute for the content to appear in search results on the frontend.
This applies to articles (com_content) and content from extensions.
The issue only occurs with new content, not when modifying existing content.
Testing instructions
Example: Create a new article, e.g. at 12:00:05.
Start a search for this article in the frontend in the same minute (still at 12:00:xx).
Expected result
The article is found immediately.
Actual result
The article is not found at 12:00:xx, but after 12:01:00.
I suspect the cause lies in line 177 of the file searchmodel.php:
|
// Get the current date, minus seconds. |
|
$nowDate = $db->quote(substr_replace(Factory::getDate()->toSql(), '00', -2)); |
Is there a specific reason for this change to the time ($nowDate)?
On a normal (live) website, this delay is probably not a problem.
However, if developers/testers create content for testing purposes, for example to test a finder plugin, this can lead to confusion.
System Information
Tested with Joomla 5.4.5 and 6.1.0
PHP 8.3
When new content is created, it can take up to one minute for the content to appear in search results on the frontend.
This applies to articles (com_content) and content from extensions.
The issue only occurs with new content, not when modifying existing content.
Testing instructions
Example: Create a new article, e.g. at 12:00:05.
Start a search for this article in the frontend in the same minute (still at 12:00:xx).
Expected result
The article is found immediately.
Actual result
The article is not found at 12:00:xx, but after 12:01:00.
I suspect the cause lies in line 177 of the file searchmodel.php:
joomla-cms/components/com_finder/src/Model/SearchModel.php
Lines 176 to 177 in aa77185
Is there a specific reason for this change to the time ($nowDate)?
On a normal (live) website, this delay is probably not a problem.
However, if developers/testers create content for testing purposes, for example to test a finder plugin, this can lead to confusion.
System Information
Tested with Joomla 5.4.5 and 6.1.0
PHP 8.3