Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

Commit

Permalink
sdi-1177 make consistent behavior for RecordFailure
Browse files Browse the repository at this point in the history
  • Loading branch information
candysmurf committed May 26, 2016
1 parent c0a14c7 commit 0433b6e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scheduler/workflow.go
Original file line number Diff line number Diff line change
Expand Up @@ -318,8 +318,8 @@ func (s *schedulerWorkflow) Start(t *task) {
// Block until the job has been either run or skipped.
errors := t.manager.Work(j).Promise().Await()

if len(errors) != 0 {
t.RecordFailure(j.Errors())
if len(errors) > 0 {
t.RecordFailure(errors)
event := new(scheduler_event.MetricCollectionFailedEvent)
event.TaskID = t.id
event.Errors = errors
Expand Down

0 comments on commit 0433b6e

Please sign in to comment.