applications that are using joomla's cache handler:
$cache = JFactory::getCache('my_key','callback');
$cache->setCaching(true);
$cache->call( array( 'MyClass', 'MyFunction' ),$param1,$param2,$param3);
the cache handlers in joomla do usleep on a first round even when the key hasn't yet been created within the cache handlers.
related joomla core files with usleep:
\libraries\joomla\cache\storage\file.php
\libraries\joomla\cache\cache.php
original code in file.php
[code]
usleep(100);
$data_lock = @flock($_fileopen, LOCK_EX);
[/code]
suggested code (to usleep only after the first round):
[code]
$data_lock = @flock($_fileopen, LOCK_EX);
if ($data_lock === false) {
usleep(100);
}
[/code]
since locking is handled in the handler (file and others) i do not see the point to delay script with usleep in the main cache class:
\libraries\joomla\cache\cache.php
adding Nx 2x 100 microsends to the page load depending on N number of times of calling the cache function while having an empty cache.
slow site, lower SEO
php 5.5 on joomla 3.5.1
Category | ⇒ | Cache |
Priority | Urgent | ⇒ | Medium |
As you have allready code you can submit them as pull request with test instructions
If you need help please see here: https://docs.joomla.org/Using_the_Github_UI_to_Make_Pull_Requests
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2016-07-30 20:36:43 |
Closed_By | ⇒ | zero-24 |
Set to "closed" on behalf of @zero-24 by The JTracker Application at issues.joomla.org/joomla-cms/10706
Closing as we have a PR for testing. Thanks @csthomas
Reset priority according to documented standards https://docs.joomla.org/Priority
This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/10706.