Delete orphaned/expired advagg locks from the semaphore database table.
Return value
int Count of the number of rows removed from the databases.
2 calls to advagg_cleanup_semaphore_table()
- advagg_admin_cleanup_semaphore_table_button dans ./
advagg.admin.inc - Delete orphaned/expired advagg locks from the semaphore database table.
- advagg_cron dans ./
advagg.module - Implements hook_cron().
Fichier
-
./
advagg.cache.inc, line 685
Code
function advagg_cleanup_semaphore_table() {
// Let expiration times vary by 5 minutes.
$fuzz_factor = 300;
$results = db_delete('semaphore')->condition('name', db_like('advagg_') . '%', 'LIKE')
->condition('expire', REQUEST_TIME - $fuzz_factor, '<')
->execute();
return $results;
}