[
https://issues.apache.org/jira/browse/YARN-10646?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Szilard Nemeth updated YARN-10646:
----------------------------------
Parent Issue: YARN-10888 (was: YARN-10496)
> TestCapacitySchedulerWeightMode test descriptor comments doesn't reflect the
> correct scenario
> ---------------------------------------------------------------------------------------------
>
> Key: YARN-10646
> URL: https://issues.apache.org/jira/browse/YARN-10646
> Project: Hadoop YARN
> Issue Type: Sub-task
> Environment:
> Reporter: Benjamin Teke
> Assignee: Benjamin Teke
> Priority: Major
>
> There is a mixup in TestCapacitySchedulerWeightMode in the configuration
> creator method comments and the test case descriptor comments. See the
> following code:
> {code:java}
> /*
> * Queue structure:
> * root (*)
> * _______________________
> * / \
> * a x(=100%), y(50%) b y(=50%), z(=100%)
> * ________________ ______________
> * / / \
> * a1 ([x,y]: w=100) b1(no) b2([y,z]: w=100)
> *
> * Parent uses weight, child uses percentage
> */
> public static Configuration getCSConfWithLabelsParentUsePctChildUseWeight(
> Configuration config) {
> {code}
> While inside the method all the queues (including the second level ones) are
> configured with capacity, only some labels are configured with weights:
> {code:java}
> conf.setLabeledQueueWeight(CapacitySchedulerConfiguration.ROOT, "x", 100);
> conf.setLabeledQueueWeight(CapacitySchedulerConfiguration.ROOT, "y", 100);
> conf.setLabeledQueueWeight(CapacitySchedulerConfiguration.ROOT, "z", 100);
> ...
> conf.setQueues(A, new String[] { "a1" });
> conf.setCapacityByLabel(A1, RMNodeLabelsManager.NO_LABEL, 100);
> conf.setMaximumCapacity(A1, 100);
> conf.setAccessibleNodeLabels(A1, toSet("x", "y"));
> conf.setDefaultNodeLabelExpression(A1, "x");
> conf.setCapacityByLabel(A1, "x", 100);
> conf.setCapacityByLabel(A1, "y", 100);
> conf.setQueues(B, new String[] { "b1", "b2" });
> conf.setCapacityByLabel(B1, RMNodeLabelsManager.NO_LABEL, 50);
> conf.setMaximumCapacity(B1, 50);
> conf.setAccessibleNodeLabels(B1, RMNodeLabelsManager.EMPTY_STRING_SET);
> conf.setCapacityByLabel(B2, RMNodeLabelsManager.NO_LABEL, 50);
> conf.setMaximumCapacity(B2, 50);
> conf.setAccessibleNodeLabels(B2, toSet("y", "z"));
> conf.setCapacityByLabel(B2, "y", 100);
> conf.setCapacityByLabel(B2, "z", 100);
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]