Skip to content

Commit

Permalink
fix logic in markAsUnscheduledFor
Browse files Browse the repository at this point in the history
  • Loading branch information
Arvindthiru committed Oct 24, 2024
1 parent 34dafc3 commit ebec2b7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/scheduler/framework/framework.go
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,10 @@ func (f *framework) markAsUnscheduledFor(ctx context.Context, bindings []*placem
// We will just retry for conflict errors since the scheduler holds the truth here.
if apierrors.IsConflict(err) {
// get the binding again to make sure we have the latest version to update again.
return f.client.Get(cctx, client.ObjectKeyFromObject(unscheduledBinding), unscheduledBinding)
getErr := f.client.Get(cctx, client.ObjectKeyFromObject(unscheduledBinding), unscheduledBinding)
if getErr != nil {
return getErr
}
}
return err
})
Expand Down

0 comments on commit ebec2b7

Please sign in to comment.