Skip to content

Commit

Permalink
[YUNIKORN-2806] Fix deadlock in Preemptor.findEligiblePreemptionVicti…
Browse files Browse the repository at this point in the history
…ms() (apache#948)

Preemptor.findEligiblePreemptionVictims() needs to disregard apps in the
current queue to avoid a recursive deadlock.

Closes: apache#948
  • Loading branch information
craigcondit committed Aug 15, 2024
1 parent 7c5b325 commit f51aaba
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/scheduler/objects/queue.go
Original file line number Diff line number Diff line change
Expand Up @@ -1769,6 +1769,9 @@ func (sq *Queue) findEligiblePreemptionVictims(results map[string]*QueuePreempti
if sq == nil {
return
}
if sq.GetQueuePath() == queuePath {
return
}
if sq.IsLeafQueue() {
// leaf queue, skip queue if preemption is disabled
if sq.GetPreemptionPolicy() == policies.DisabledPreemptionPolicy {
Expand Down

0 comments on commit f51aaba

Please sign in to comment.