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

Wilfred Spiegelenburg edited comment on YUNIKORN-1650 at 3/27/23 1:48 AM:
--------------------------------------------------------------------------

Backwards compatible behaviour is always better. I skipped over that when I 
wrote the update. Checking for an empty value would get us that, +1 on that. 
Does this cover us including backwards compatibility?

Admission controller {{defaultQueue}} configuration setting:
 * yunikorn-defaults does not contain the setting
 * if the configuration setting is not set we assume "root.default" and process 
as we did per the existing behaviour
 * if the configuration value is set _and_ empty we do not set the queue 
label/annotation on the pod
 * if the configuration value is set and _not empty_ the label/annotation is 
set to the configured value

The config map allows us to detect if the config key is set. That is simpler 
than using a separate boolean. The boolean would only trigger a read of a 
second value which still could be empty.

Even if we then set the configuration in the yunikorn-defaults to 
"root.default" we are backwards compatible. But I would rather not set it at 
all.


was (Author: wifreds):
Backwards compatible behaviour is always better. I skipped over that when I 
wrote the update. Checking for an empty value would get us that, +1 on that. 
Does this cover us including backwards compatibility?

Admission controller {{defaultQueue}} configuration setting:
 * yunikorn-defaults does not contain the setting
 * if the configuration setting is not set we assume "root.default" and process 
as we did per the existing behaviour
 * if the configuration value is set _and_ empty we do not set the queue 
label/annotation on the pod
 * if the configuration value is set and _not empty_ the label/annotation is 
set to the configured value

> Add toggle for adding default queue in admission controller
> -----------------------------------------------------------
>
>                 Key: YUNIKORN-1650
>                 URL: https://issues.apache.org/jira/browse/YUNIKORN-1650
>             Project: Apache YuniKorn
>          Issue Type: Improvement
>          Components: shim - kubernetes
>            Reporter: Mit Desai
>            Assignee: Mit Desai
>            Priority: Major
>
> If the queue name is not defined during the job submission, YuniKorn 
> admission controller will add a default queue to the pod labels.
> When _provided_ placement rule is defined, along with other placement rules, 
> it is possible that only provided placement rule is executed and no other 
> rule is exercised.
> In the following scenario, when there are 3 placement rules defined,
> placementrules:
>         - name: provided
>         - name: tag
>         - name: fixed
> The applications will be placed in the right queue, following the _provided_ 
> rule if the queue is defined during job submission. If the queue is not 
> defined during job submission, admission controller will add a default queue 
> name. This will again trigger the provided rule as the queue name will be 
> found in the pod labels during placement rules execution. As a result, _tag_ 
> and _fixed_ rules will never be executed and all the apps that do not have a 
> queue defined will end up getting placed in the default queue.
> To solve this, we should have a toggle in the admission controller configs 
> whether to add the default queue to or not. Whenever such placement rules are 
> setup, admission controller should be configured to skip adding the default 
> queue name.



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