Copilot commented on code in PR #8618:
URL: https://github.com/apache/hadoop/pull/8618#discussion_r3618416546
##########
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/ManagedParentQueue.java:
##########
@@ -262,6 +262,26 @@ private void updateQueueCapacities(QueueCapacities
queueCapacities) {
}
}
+/**
+ * Recomputes leaf queue template capacities in ABSOLUTE_RESOURCE mode.
+ * This handles the case where a queue is recreated during RM recovery
+ * before any NodeManager has registered, causing the initial capacity
+ * to be computed as 0. The periodic queue management policy recalculates
+ * the template once cluster resources become available. No operation for other
+ * queue modes.
+ */
Review Comment:
The Javadoc for the new method is not indented consistently with other
method-level Javadocs in this class (e.g., the Javadoc starting at line 436).
This kind of indentation inconsistency can also trip style checks in this
module; align it with the surrounding convention.
##########
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/queuemanagement/GuaranteedOrZeroCapacityOverTimePolicy.java:
##########
@@ -310,6 +312,15 @@ private void
initializeLeafQueueTemplate(ManagedParentQueue parentQueue)
public List<QueueManagementChange> computeQueueManagementChanges()
throws SchedulerDynamicEditException {
+ // Recompute the leaf queue template capacities from the current cluster
+ // resource for ABSOLUTE_RESOURCE mode. The template fraction is otherwise
+ // computed only at reinitialize; if a leaf queue was auto-created
+ // while the cluster resource was zero during RM recovery before any
Review Comment:
Extra whitespace in this comment ("zero during") looks like an accidental
typo; please remove the double space to keep comments clean and searchable.
--
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]