Copilot commented on code in PR #8547:
URL: https://github.com/apache/hadoop/pull/8547#discussion_r3414873841
##########
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/webapp/TestRMWebServicesForCSWithPartitions.java:
##########
@@ -338,6 +338,47 @@ public void testSchedulerPartitionsXML(boolean
pLegacyQueueMode)
verifySchedulerInfoXML(dom);
}
+ @MethodSource("getParameters")
+ @ParameterizedTest(name = "{index}: legacy-queue-mode={0}")
+ public void testClusterMetricsWithPartitions(boolean pLegacyQueueMode)
+ throws Exception {
+ initTestRMWebServicesForCSWithPartitions(pLegacyQueueMode);
+ WebTarget r = targetWithJsonObject();
+ Response response = r.path("ws").path("v1").path("cluster")
+
.path("metrics").request(MediaType.APPLICATION_JSON).get(Response.class);
Review Comment:
`/ws/v1/cluster/metrics` supports both JSON and XML responses, but the new
partition-aware fields are only covered by a JSON test here. Adding an XML
variant would help ensure JAXB/MOXy marshalling of `partitionClusterMetrics`
and the cross-partition resource fields remains compatible for XML clients.
--
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]