You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@yunikorn.apache.org by "Hedger Lai (Jira)" <ji...@apache.org> on 2026/09/17 17:52:00 UTC

[jira] [Created] (YUNIKORN-3458) Premature victim loop termination in calculateVictimsByNode starves preemption

Hedger Lai created YUNIKORN-3458:
------------------------------------

             Summary: Premature victim loop termination in calculateVictimsByNode starves preemption
                 Key: YUNIKORN-3458
                 URL: https://issues.apache.org/jira/browse/YUNIKORN-3458
             Project: Apache YuniKorn
          Issue Type: Bug
          Components: core - scheduler
            Reporter: Hedger Lai
            Assignee: Hedger Lai
             Fix For: 1.6.0


In {{calculateVictimsByNode()}} ({{preemption.go}}), when a candidate victim exceeds {{askQueueRemaining}}, the loop executes {{break}}:

{code:go}
if askQueueRemaining != nil && askQueueRemaining.FitInActual(victim.GetAllocatedResource()) {
    askQueue.AddAllocation(victim.GetAllocatedResource())
} else {
    queueSnapshot.AddAllocation(victim.GetAllocatedResource())
    break
}
{code}

This prematurely aborts victim evaluation for the node, ignoring subsequent viable victims and causing preemption to fail.

h3. Proposed Fix
Change {{break}} to {{continue}}.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@yunikorn.apache.org
For additional commands, e-mail: issues-help@yunikorn.apache.org