TaoYang526 commented on code in PR #7121:
URL: https://github.com/apache/hadoop/pull/7121#discussion_r1806043603
##########
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/placement/MultiNodePolicySpec.java:
##########
@@ -22,14 +22,25 @@
*/
public class MultiNodePolicySpec {
+ private String policyName;
private String policyClassName;
private long sortingInterval;
- public MultiNodePolicySpec(String policyClassName, long timeout) {
+ public MultiNodePolicySpec(String policyName, String policyClassName,
Review Comment:
In MultiNodeSorter#initPolicy, Policy instance will be created based on
policyClassName, and policyName will be used to get conf belong to this policy
instance in MultiComparatorPolicy#setConf. This is the only way for every
policy instance to know which configuration belong to it, another way is to
update the policy interface that I prefer not to use. If there are better
approaches, feel free to propose them.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]