You are viewing a plain text version of this content. The canonical link for it is here.
Posted to yarn-issues@hadoop.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2022/10/01 10:40:00 UTC
[jira] [Commented] (YARN-11317) [Federation] Refactoring Yarn Router's About Web Page.
[ https://issues.apache.org/jira/browse/YARN-11317?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17611865#comment-17611865 ]
ASF GitHub Bot commented on YARN-11317:
---------------------------------------
slfan1989 commented on code in PR #4946:
URL: https://github.com/apache/hadoop/pull/4946#discussion_r985083565
##########
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/webapp/TestRMWebServices.java:
##########
@@ -1099,4 +1099,63 @@ private RMWebServices prepareWebServiceForValidation(
return webService;
}
+ @Test
+ public void testClusterSchedulerOverviewFifo() throws JSONException, Exception {
+ WebResource r = resource();
+ ClientResponse response = r.path("ws").path("v1").path("cluster")
+ .path("scheduler-overview").accept(MediaType.APPLICATION_JSON)
+ .get(ClientResponse.class);
+
+ assertEquals(MediaType.APPLICATION_JSON + "; " + JettyUtils.UTF_8,
+ response.getType().toString());
+ JSONObject json = response.getEntity(JSONObject.class);
+ verifyClusterSchedulerFifoOverView(json);
+ System.out.println(json);
+ }
+
+ public void verifyClusterSchedulerFifoOverView(JSONObject json)
+ throws Exception {
+
+ // why json contains 8 elements because we defined 8 fields
+ assertEquals("incorrect number of elements in: " + json, 8, json.length());
+
+ // 1.Verify that the schedulerType is as expected
+ String schedulerType = json.getString("schedulerType");
+ Assert.assertEquals("Fifo Scheduler", schedulerType);
+ System.out.println(schedulerType);
+
+ // 2.Verify that schedulingResourceType is as expected
+ String schedulingResourceType = json.getString("schedulingResourceType");
+ Assert.assertEquals("memory-mb (unit=Mi),vcores", schedulingResourceType);
Review Comment:
I will fix it.
> [Federation] Refactoring Yarn Router's About Web Page.
> ------------------------------------------------------
>
> Key: YARN-11317
> URL: https://issues.apache.org/jira/browse/YARN-11317
> Project: Hadoop YARN
> Issue Type: Improvement
> Components: federation
> Affects Versions: 3.4.0
> Reporter: fanshilun
> Assignee: fanshilun
> Priority: Major
> Labels: pull-request-available
> Attachments: image-2022-09-25-12-33-58-099.png, image-2022-09-28-23-12-37-821.png, image-2022-09-28-23-42-15-475.png, image-2022-09-29-12-35-59-534.png, image-2022-09-29-12-46-59-592.png
>
>
> Optimize Yarn Federation Router About page
> 1. Make the page more similar to the Yarn RM page style
> 2. Add more friendly tips.
>
> Before page optimization:
> !image-2022-09-25-12-33-58-099.png|width=982,height=417!
> After page optimization:
> Enable Yarn Federation :
> !image-2022-09-29-12-46-59-592.png|width=947,height=431!
> Not Enable Yarn Federation:
> !image-2022-09-29-12-35-59-534.png|width=977,height=414!
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: yarn-issues-help@hadoop.apache.org