mirror of
https://git.tt-rss.org/fox/tt-rss.git
synced 2025-08-07 14:47:26 +02:00
adjust scheduler logging to be somewhat more alike to feed updater
This commit is contained in:
parent
997c10437e
commit
4cda1da5c0
@ -74,7 +74,7 @@ class Scheduler {
|
|||||||
// because we don't schedule tasks every minute, we assume that task is due if its
|
// because we don't schedule tasks every minute, we assume that task is due if its
|
||||||
// next estimated run based on previous timestamp is in the past
|
// next estimated run based on previous timestamp is in the past
|
||||||
if ($task['cron']->getNextRunDate($last_run)->getTimestamp() - time() < 0) {
|
if ($task['cron']->getNextRunDate($last_run)->getTimestamp() - time() < 0) {
|
||||||
Debug::log("Task $task_name is due, executing...");
|
Debug::log("=> Scheduled task $task_name is due, executing...");
|
||||||
|
|
||||||
$task_started = time();
|
$task_started = time();
|
||||||
|
|
||||||
@ -90,10 +90,10 @@ class Scheduler {
|
|||||||
|
|
||||||
if ($rc === 0) {
|
if ($rc === 0) {
|
||||||
++$tasks_succeeded;
|
++$tasks_succeeded;
|
||||||
Debug::log("Task $task_name has finished in $task_duration seconds.");
|
Debug::log("<= Scheduled task $task_name has finished in $task_duration seconds.");
|
||||||
} else {
|
} else {
|
||||||
$tasks_failed++;
|
$tasks_failed++;
|
||||||
Debug::log("Task $task_name has failed with RC: $rc after $task_duration seconds.");
|
Debug::log("!! Scheduled task $task_name has failed with RC: $rc after $task_duration seconds.");
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($task_record) {
|
if ($task_record) {
|
||||||
@ -117,7 +117,7 @@ class Scheduler {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Debug::log("Finished with $tasks_succeeded tasks succeeded and $tasks_failed tasks failed.");
|
Debug::log("Processing scheduled tasks finished with $tasks_succeeded tasks succeeded and $tasks_failed tasks failed.");
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO implement some sort of automatic cleanup for orphan task execution records
|
// TODO implement some sort of automatic cleanup for orphan task execution records
|
||||||
|
Loading…
Reference in New Issue
Block a user