[ 
https://issues.apache.org/jira/browse/YUNIKORN-3147?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Hsien-Cheng(Ryan) Huang updated YUNIKORN-3147:
----------------------------------------------
    Description: 
in checking logs, using a deterministic log[0] to check. 
But, the logs somehow goes in different order

err:

{code:java}
Entry 0: &{Message:Not enough queue quota LastOccurrence:2025-11-01 
16:51:09.930115 +0800 CST m=+0.010604542 Count:1}
Entry 1: &{Message:Preemption max attempts exhausted LastOccurrence:2025-11-01 
16:51:09.930114 +0800 CST m=+0.010603709 Count:1}
Entry 2: &{Message:Preemption does not help LastOccurrence:2025-11-01 
16:51:09.930114 +0800 CST m=+0.010604251 Count:1}
{code}

normal:
{code:java}
Entry 0: &{Message:Preemption max attempts exhausted LastOccurrence:2025-11-01 
16:52:48.659237 +0800 CST m=+0.011641251 Count:1}
Entry 1: &{Message:Preemption does not help LastOccurrence:2025-11-01 
16:52:48.659237 +0800 CST m=+0.011641709 Count:1}
Entry 2: &{Message:Not enough queue quota LastOccurrence:2025-11-01 
16:52:48.659238 +0800 CST m=+0.011641959 Count:1}
{code}


test err msg:

{code:java}
=== RUN   TestTryAllocatePreemptQueue
2025-11-01T17:23:47.342+0800    INFO    core.scheduler.queue    
objects/queue.go:154    configured queue added to scheduler     {"queueName": 
"root"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
objects/queue.go:1374   updating root queue max resources       {"current max": 
"nil resource", "new max": "map[first:20]"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
objects/queue.go:154    configured queue added to scheduler     {"queueName": 
"root.parent"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
objects/queue.go:154    configured queue added to scheduler     {"queueName": 
"root.parent.child1"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
objects/queue.go:154    configured queue added to scheduler     {"queueName": 
"root.parent.child2"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:163      Unknown gang scheduling style, using soft style 
as default      {"gang scheduling style": ""}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.fsm      
objects/application_state.go:147Application state transition    {"appID": 
"app-1", "source": "New", "destination": "Accepted", "event": "runApplication"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:633      ask added successfully to application   
{"appID": "app-1", "user": "testuser", "ask": "alloc1", "placeholder": false, 
"pendingDelta": "map[first:5]"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:633      ask added successfully to application   
{"appID": "app-1", "user": "testuser", "ask": "alloc2", "placeholder": false, 
"pendingDelta": "map[first:5]"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:163      Unknown gang scheduling style, using soft style 
as default      {"gang scheduling style": ""}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.fsm      
objects/application_state.go:147Application state transition    {"appID": 
"app-2", "source": "New", "destination": "Accepted", "event": "runApplication"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:633      ask added successfully to application   
{"appID": "app-2", "user": "testuser", "ask": "alloc3", "placeholder": false, 
"pendingDelta": "map[first:5]"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
ugm/manager.go:634      User tracker doesn't exists. Creating user tracker.     
{"user": "testuser"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
ugm/manager.go:254      Group tracker set for user application  {"group": "", 
"user": "testuser", "application": "app-1", "queue path": "root.parent.child1"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.node     
objects/node.go:429     node allocation processed       {"appID": "app-1", 
"allocationKey": "alloc1", "allocatedResource": "map[first:5]", "placeholder": 
false, "targetNode": "node1"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.fsm      
objects/application_state.go:147Application state transition    {"appID": 
"app-1", "source": "Accepted", "destination": "Running", "event": 
"runApplication"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.node     
objects/node.go:429     node allocation processed       {"appID": "app-1", 
"allocationKey": "alloc2", "allocatedResource": "map[first:5]", "placeholder": 
false, "targetNode": "node1"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
ugm/manager.go:254      Group tracker set for user application  {"group": "", 
"user": "testuser", "application": "app-2", "queue path": "root.parent.child2"}
    application_test.go:2246: assertion failed: Preemption does not help 
(log[0].Message string) != Preemption max attempts exhausted 
(common.PreemptionMaxAttemptsExhausted string)
--- FAIL: TestTryAllocatePreemptQueue (0.01s)
FAIL
FAIL    github.com/apache/yunikorn-core/pkg/scheduler/objects   0.317s
FAIL
{code}

  was:
in checking logs, using a deterministic log[0] to check. 
But, the logs somehow goes in different order

err:

{code:java}
Entry 0: &{Message:Not enough queue quota LastOccurrence:2025-11-01 
16:51:09.930115 +0800 CST m=+0.010604542 Count:1}
Entry 1: &{Message:Preemption max attempts exhausted LastOccurrence:2025-11-01 
16:51:09.930114 +0800 CST m=+0.010603709 Count:1}
Entry 2: &{Message:Preemption does not help LastOccurrence:2025-11-01 
16:51:09.930114 +0800 CST m=+0.010604251 Count:1}
{code}

normal:
{code:java}
Entry 0: &{Message:Preemption max attempts exhausted LastOccurrence:2025-11-01 
16:52:48.659237 +0800 CST m=+0.011641251 Count:1}
Entry 1: &{Message:Preemption does not help LastOccurrence:2025-11-01 
16:52:48.659237 +0800 CST m=+0.011641709 Count:1}
Entry 2: &{Message:Not enough queue quota LastOccurrence:2025-11-01 
16:52:48.659238 +0800 CST m=+0.011641959 Count:1}
{code}


{code:java}
=== RUN   TestTryAllocatePreemptQueue
2025-11-01T17:23:47.342+0800    INFO    core.scheduler.queue    
objects/queue.go:154    configured queue added to scheduler     {"queueName": 
"root"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
objects/queue.go:1374   updating root queue max resources       {"current max": 
"nil resource", "new max": "map[first:20]"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
objects/queue.go:154    configured queue added to scheduler     {"queueName": 
"root.parent"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
objects/queue.go:154    configured queue added to scheduler     {"queueName": 
"root.parent.child1"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
objects/queue.go:154    configured queue added to scheduler     {"queueName": 
"root.parent.child2"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:163      Unknown gang scheduling style, using soft style 
as default      {"gang scheduling style": ""}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.fsm      
objects/application_state.go:147Application state transition    {"appID": 
"app-1", "source": "New", "destination": "Accepted", "event": "runApplication"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:633      ask added successfully to application   
{"appID": "app-1", "user": "testuser", "ask": "alloc1", "placeholder": false, 
"pendingDelta": "map[first:5]"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:633      ask added successfully to application   
{"appID": "app-1", "user": "testuser", "ask": "alloc2", "placeholder": false, 
"pendingDelta": "map[first:5]"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:163      Unknown gang scheduling style, using soft style 
as default      {"gang scheduling style": ""}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.fsm      
objects/application_state.go:147Application state transition    {"appID": 
"app-2", "source": "New", "destination": "Accepted", "event": "runApplication"}
2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
objects/application.go:633      ask added successfully to application   
{"appID": "app-2", "user": "testuser", "ask": "alloc3", "placeholder": false, 
"pendingDelta": "map[first:5]"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
ugm/manager.go:634      User tracker doesn't exists. Creating user tracker.     
{"user": "testuser"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
ugm/manager.go:254      Group tracker set for user application  {"group": "", 
"user": "testuser", "application": "app-1", "queue path": "root.parent.child1"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.node     
objects/node.go:429     node allocation processed       {"appID": "app-1", 
"allocationKey": "alloc1", "allocatedResource": "map[first:5]", "placeholder": 
false, "targetNode": "node1"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.fsm      
objects/application_state.go:147Application state transition    {"appID": 
"app-1", "source": "Accepted", "destination": "Running", "event": 
"runApplication"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.node     
objects/node.go:429     node allocation processed       {"appID": "app-1", 
"allocationKey": "alloc2", "allocatedResource": "map[first:5]", "placeholder": 
false, "targetNode": "node1"}
2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
ugm/manager.go:254      Group tracker set for user application  {"group": "", 
"user": "testuser", "application": "app-2", "queue path": "root.parent.child2"}
    application_test.go:2246: assertion failed: Preemption does not help 
(log[0].Message string) != Preemption max attempts exhausted 
(common.PreemptionMaxAttemptsExhausted string)
--- FAIL: TestTryAllocatePreemptQueue (0.01s)
FAIL
FAIL    github.com/apache/yunikorn-core/pkg/scheduler/objects   0.317s
FAIL
{code}


> Flaky test on ./pkg/scheduler/objects -run ^TestTryAllocatePreemptQueue$
> ------------------------------------------------------------------------
>
>                 Key: YUNIKORN-3147
>                 URL: https://issues.apache.org/jira/browse/YUNIKORN-3147
>             Project: Apache YuniKorn
>          Issue Type: Test
>            Reporter: Hsien-Cheng(Ryan) Huang
>            Assignee: Hsien-Cheng(Ryan) Huang
>            Priority: Minor
>
> in checking logs, using a deterministic log[0] to check. 
> But, the logs somehow goes in different order
> err:
> {code:java}
> Entry 0: &{Message:Not enough queue quota LastOccurrence:2025-11-01 
> 16:51:09.930115 +0800 CST m=+0.010604542 Count:1}
> Entry 1: &{Message:Preemption max attempts exhausted 
> LastOccurrence:2025-11-01 16:51:09.930114 +0800 CST m=+0.010603709 Count:1}
> Entry 2: &{Message:Preemption does not help LastOccurrence:2025-11-01 
> 16:51:09.930114 +0800 CST m=+0.010604251 Count:1}
> {code}
> normal:
> {code:java}
> Entry 0: &{Message:Preemption max attempts exhausted 
> LastOccurrence:2025-11-01 16:52:48.659237 +0800 CST m=+0.011641251 Count:1}
> Entry 1: &{Message:Preemption does not help LastOccurrence:2025-11-01 
> 16:52:48.659237 +0800 CST m=+0.011641709 Count:1}
> Entry 2: &{Message:Not enough queue quota LastOccurrence:2025-11-01 
> 16:52:48.659238 +0800 CST m=+0.011641959 Count:1}
> {code}
> test err msg:
> {code:java}
> === RUN   TestTryAllocatePreemptQueue
> 2025-11-01T17:23:47.342+0800    INFO    core.scheduler.queue    
> objects/queue.go:154    configured queue added to scheduler     {"queueName": 
> "root"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
> objects/queue.go:1374   updating root queue max resources       {"current 
> max": "nil resource", "new max": "map[first:20]"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
> objects/queue.go:154    configured queue added to scheduler     {"queueName": 
> "root.parent"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
> objects/queue.go:154    configured queue added to scheduler     {"queueName": 
> "root.parent.child1"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.queue    
> objects/queue.go:154    configured queue added to scheduler     {"queueName": 
> "root.parent.child2"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
> objects/application.go:163      Unknown gang scheduling style, using soft 
> style as default      {"gang scheduling style": ""}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.fsm      
> objects/application_state.go:147Application state transition    {"appID": 
> "app-1", "source": "New", "destination": "Accepted", "event": 
> "runApplication"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
> objects/application.go:633      ask added successfully to application   
> {"appID": "app-1", "user": "testuser", "ask": "alloc1", "placeholder": false, 
> "pendingDelta": "map[first:5]"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
> objects/application.go:633      ask added successfully to application   
> {"appID": "app-1", "user": "testuser", "ask": "alloc2", "placeholder": false, 
> "pendingDelta": "map[first:5]"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
> objects/application.go:163      Unknown gang scheduling style, using soft 
> style as default      {"gang scheduling style": ""}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.fsm      
> objects/application_state.go:147Application state transition    {"appID": 
> "app-2", "source": "New", "destination": "Accepted", "event": 
> "runApplication"}
> 2025-11-01T17:23:47.343+0800    INFO    core.scheduler.application      
> objects/application.go:633      ask added successfully to application   
> {"appID": "app-2", "user": "testuser", "ask": "alloc3", "placeholder": false, 
> "pendingDelta": "map[first:5]"}
> 2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
> ugm/manager.go:634      User tracker doesn't exists. Creating user tracker.   
>   {"user": "testuser"}
> 2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
> ugm/manager.go:254      Group tracker set for user application  {"group": "", 
> "user": "testuser", "application": "app-1", "queue path": 
> "root.parent.child1"}
> 2025-11-01T17:23:47.344+0800    INFO    core.scheduler.node     
> objects/node.go:429     node allocation processed       {"appID": "app-1", 
> "allocationKey": "alloc1", "allocatedResource": "map[first:5]", 
> "placeholder": false, "targetNode": "node1"}
> 2025-11-01T17:23:47.344+0800    INFO    core.scheduler.fsm      
> objects/application_state.go:147Application state transition    {"appID": 
> "app-1", "source": "Accepted", "destination": "Running", "event": 
> "runApplication"}
> 2025-11-01T17:23:47.344+0800    INFO    core.scheduler.node     
> objects/node.go:429     node allocation processed       {"appID": "app-1", 
> "allocationKey": "alloc2", "allocatedResource": "map[first:5]", 
> "placeholder": false, "targetNode": "node1"}
> 2025-11-01T17:23:47.344+0800    INFO    core.scheduler.ugm      
> ugm/manager.go:254      Group tracker set for user application  {"group": "", 
> "user": "testuser", "application": "app-2", "queue path": 
> "root.parent.child2"}
>     application_test.go:2246: assertion failed: Preemption does not help 
> (log[0].Message string) != Preemption max attempts exhausted 
> (common.PreemptionMaxAttemptsExhausted string)
> --- FAIL: TestTryAllocatePreemptQueue (0.01s)
> FAIL
> FAIL    github.com/apache/yunikorn-core/pkg/scheduler/objects   0.317s
> FAIL
> {code}



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

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to