Skip to content

Commit

Permalink
Skip early when reclaimees is empty
Browse files Browse the repository at this point in the history
Signed-off-by: Binbin Zou <binbin.zou@kyligence.io>
  • Loading branch information
Binbin Zou committed Mar 10, 2023
1 parent 12a44e3 commit 1f34948
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pkg/scheduler/actions/reclaim/reclaim.go
Expand Up @@ -152,6 +152,11 @@ func (ra *Action) Execute(ssn *framework.Session) {
reclaimees = append(reclaimees, task.Clone())
}
}

if len(reclaimees) == 0 {
continue
}

victims := ssn.Reclaimable(task, reclaimees)

if err := util.ValidateVictims(task, n, victims); err != nil {
Expand Down

0 comments on commit 1f34948

Please sign in to comment.