From 95fe2e7641de142a82fc6f82db8cf14c1e6e52a1 Mon Sep 17 00:00:00 2001 From: Ben Roberts Date: Sun, 21 Aug 2011 16:11:51 +0100 Subject: [PATCH] Add additional logging for batch job runner --- webui/run-jobs.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/webui/run-jobs.php b/webui/run-jobs.php index 7fdb68a..4ed5941 100644 --- a/webui/run-jobs.php +++ b/webui/run-jobs.php @@ -29,8 +29,12 @@ try { $set->addTask($task); $job->updateStatus(RippingCluster_JobStatus::QUEUED); + RippingCluster_ClientLogEntry::info($log, $rip_options['id'], 'Job queued', 'client'); } + $job_count = count($jobs); + RippingCluster_ClientLogEntry::info($log, null, "Job queue started with {$job_count} jobs.", 'batch'); + // Start the job queue $result = $client->runSet($set); @@ -58,7 +62,7 @@ function gearman_fail($task) { $job = RippingCluster_Job::fromId($task->arg['rip_options']['id']); $job->updateStatus(RippingCluster_JobStatus::FAILED); - RippingCluster_ClientLogEntry::info($log, $job->id(), 'Job failed'); + RippingCluster_ClientLogEntry::info($log, $job->id(), "Job failed with message: {$task->result}"); }