Split cron tasks in several worker tasks
This commit is contained in:
@@ -37,9 +37,6 @@ class ClearCache
|
||||
|
||||
// clear old cache
|
||||
DI::cache()->clear();
|
||||
if (DI::config()->get('system', 'optimize_tables')) {
|
||||
DBA::e("OPTIMIZE TABLE `cache`");
|
||||
}
|
||||
|
||||
// clear old item cache files
|
||||
clear_cache();
|
||||
@@ -66,14 +63,8 @@ class ClearCache
|
||||
|
||||
// Delete the cached OEmbed entries that are older than three month
|
||||
DBA::delete('oembed', ["`created` < NOW() - INTERVAL 3 MONTH"]);
|
||||
if (DI::config()->get('system', 'optimize_tables')) {
|
||||
DBA::e("OPTIMIZE TABLE `oembed`");
|
||||
}
|
||||
|
||||
// Delete the cached "parse_url" entries that are older than three month
|
||||
DBA::delete('parsed_url', ["`created` < NOW() - INTERVAL 3 MONTH"]);
|
||||
if (DI::config()->get('system', 'optimize_tables')) {
|
||||
DBA::e("OPTIMIZE TABLE `parsed_url`");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user