[ 
https://issues.apache.org/jira/browse/YUNIKORN-2201?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17790926#comment-17790926
 ] 

Wilfred Spiegelenburg commented on YUNIKORN-2201:
-------------------------------------------------

Both checks for the queue headroom and the user headroom are simple resource 
comparisons. They will both cost the same time. We cannot cache them or 
shortcut them as each ask in the application _could_ be of a different size. So 
stating that if one ask for the application does not fit the next one will not 
fit will not hold true. Asks are sorted based on the application sort policy. 
There is no ordering on size of the ask.

Every allocation cycle that does an allocation invalidates the queue headroom. 
Every user has a headroom for a queue. An allocation in a different queue for 
the same user affects that headroom. Which again means that every allocation 
cycle needs to invalidate the user headroom as we do not, and should not, track 
when we last allocated for that user.

Any removal of an allocation, which happens outside of the scheduling cycle, 
invalidates the headroom. As soon as an allocation is removed headroom grows. 
This could even happen mid scheduling tries for different applications in a 
leaf queue. Node additions and removals will also invalidate the headroom in 
multiple ways.

Keeping track of the what and when is changing things would be adding a large 
amount of complexity. Really easy to introduce bugs and 

> Evaluate the performance impact of Headroom() and CanRunApp()
> -------------------------------------------------------------
>
>                 Key: YUNIKORN-2201
>                 URL: https://issues.apache.org/jira/browse/YUNIKORN-2201
>             Project: Apache YuniKorn
>          Issue Type: Sub-task
>          Components: core - scheduler
>            Reporter: Peter Bacsko
>            Assignee: Peter Bacsko
>            Priority: Major
>         Attachments: benchmark_maxapps_hit.png, benchmark_nolimit_hit.png, 
> benchmark_resourcequota_hit.png
>
>
> {{Manager.CanRunApp()}} and {{Manager.Headroom()}} are constantly called from 
> the scheduling cycle.
> We need to see how this affects the overall performance of Yunikorn.



--
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