From 8b969426f0e2b7207e6d20cbc030e4a55c8e4258 Mon Sep 17 00:00:00 2001 From: Nikhil Ranjan Date: Wed, 11 Sep 2019 00:23:49 +0200 Subject: [PATCH] Converting to structured logging the file jobs/jobs_watcher.go (#12121) --- jobs/jobs_watcher.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/jobs/jobs_watcher.go b/jobs/jobs_watcher.go index 632c4e3bbd..c9b4136758 100644 --- a/jobs/jobs_watcher.go +++ b/jobs/jobs_watcher.go @@ -4,7 +4,6 @@ package jobs import ( - "fmt" "math/rand" "time" @@ -68,7 +67,7 @@ func (watcher *Watcher) Stop() { func (watcher *Watcher) PollAndNotify() { jobs, err := watcher.srv.Store.Job().GetAllByStatus(model.JOB_STATUS_PENDING) if err != nil { - mlog.Error(fmt.Sprintf("Error occurred getting all pending statuses: %v", err.Error())) + mlog.Error("Error occurred getting all pending statuses.", mlog.Err(err)) return }