Skip to content

Commit a4523ec

Browse files
committed
handle error
1 parent 2feb060 commit a4523ec

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

scheduler/scheduler_system.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,9 @@ func (s *SystemScheduler) computeJobAllocs() error {
339339
// Initially, if the job requires canaries, we place all of them on all
340340
// eligible nodes. At this point we know which nodes are feasible, so we
341341
// evict unnedded canaries.
342-
s.evictCanaries(s.job, s.nodes, r)
342+
if err := s.evictCanaries(s.job, s.nodes, r); err != nil {
343+
return fmt.Errorf("failed to evict canaries for job '%s': %v", s.eval.JobID, err)
344+
}
343345

344346
// Nothing remaining to do if placement is not required
345347
if len(r.Place) == 0 {

0 commit comments

Comments
 (0)