[jira] [Commented] (YARN-11222) [Federation] Add addToClusterNodeLabels, removeFromClusterNodeLabels REST APIs for Router

2023-02-08 Thread ASF GitHub Bot (Jira)


[ 
https://issues.apache.org/jira/browse/YARN-11222?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17686247#comment-17686247
 ] 

ASF GitHub Bot commented on YARN-11222:
---

hadoop-yetus commented on PR #5328:
URL: https://github.com/apache/hadoop/pull/5328#issuecomment-1423771845

   :confetti_ball: **+1 overall**
   
   
   
   
   
   
   | Vote | Subsystem | Runtime |  Logfile | Comment |
   |::|--:|:|::|:---:|
   | +0 :ok: |  reexec  |   1m 16s |  |  Docker mode activated.  |
    _ Prechecks _ |
   | +1 :green_heart: |  dupname  |   0m  0s |  |  No case conflicting files 
found.  |
   | +0 :ok: |  codespell  |   0m  0s |  |  codespell was not available.  |
   | +0 :ok: |  detsecrets  |   0m  0s |  |  detect-secrets was not available.  
|
   | +1 :green_heart: |  @author  |   0m  1s |  |  The patch does not contain 
any @author tags.  |
   | +1 :green_heart: |  test4tests  |   0m  0s |  |  The patch appears to 
include 3 new or modified test files.  |
    _ trunk Compile Tests _ |
   | +1 :green_heart: |  mvninstall  |  48m 19s |  |  trunk passed  |
   | +1 :green_heart: |  compile  |   0m 38s |  |  trunk passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  compile  |   0m 29s |  |  trunk passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  checkstyle  |   0m 30s |  |  trunk passed  |
   | +1 :green_heart: |  mvnsite  |   0m 33s |  |  trunk passed  |
   | +1 :green_heart: |  javadoc  |   0m 35s |  |  trunk passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  javadoc  |   0m 27s |  |  trunk passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  spotbugs  |   1m  7s |  |  trunk passed  |
   | +1 :green_heart: |  shadedclient  |  26m 33s |  |  branch has no errors 
when building and testing our client artifacts.  |
    _ Patch Compile Tests _ |
   | +1 :green_heart: |  mvninstall  |   0m 35s |  |  the patch passed  |
   | +1 :green_heart: |  compile  |   0m 29s |  |  the patch passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  javac  |   0m 29s |  |  the patch passed  |
   | +1 :green_heart: |  compile  |   0m 25s |  |  the patch passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  javac  |   0m 25s |  |  the patch passed  |
   | +1 :green_heart: |  blanks  |   0m  0s |  |  The patch has no blanks 
issues.  |
   | +1 :green_heart: |  checkstyle  |   0m 16s |  |  the patch passed  |
   | +1 :green_heart: |  mvnsite  |   0m 27s |  |  the patch passed  |
   | +1 :green_heart: |  javadoc  |   0m 23s |  |  the patch passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  javadoc  |   0m 21s |  |  the patch passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  spotbugs  |   1m  4s |  |  the patch passed  |
   | +1 :green_heart: |  shadedclient  |  27m  7s |  |  patch has no errors 
when building and testing our client artifacts.  |
    _ Other Tests _ |
   | +1 :green_heart: |  unit  |   0m 33s |  |  hadoop-yarn-server-router in 
the patch passed.  |
   | +1 :green_heart: |  asflicense  |   0m 33s |  |  The patch does not 
generate ASF License warnings.  |
   |  |   | 114m  8s |  |  |
   
   
   | Subsystem | Report/Notes |
   |--:|:-|
   | Docker | ClientAPI=1.42 ServerAPI=1.42 base: 
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5328/9/artifact/out/Dockerfile
 |
   | GITHUB PR | https://github.com/apache/hadoop/pull/5328 |
   | Optional Tests | dupname asflicense compile javac javadoc mvninstall 
mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets |
   | uname | Linux f91d862a0e41 4.15.0-200-generic #211-Ubuntu SMP Thu Nov 24 
18:16:04 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux |
   | Build tool | maven |
   | Personality | dev-support/bin/hadoop.sh |
   | git revision | trunk / 75e7a42e133fb683b3b59d20d5f73cf9713fc18d |
   | Default Java | Private Build-1.8.0_352-8u352-ga-1~20.04-b08 |
   | Multi-JDK versions | 
/usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04 
/usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_352-8u352-ga-1~20.04-b08 |
   |  Test Results | 
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5328/9/testReport/ |
   | Max. process+thread count | 547 (vs. ulimit of 5500) |
   | modules | C: 
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router U: 
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router |
   | Console output | 
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5328/9/console |
   | versions | git=2.25.1 maven=3.6.3 spotbugs=4.2.2 |
   | Powered by | Apache Yetus 0.14.0 https://yetus.apache.org |
   
   
   This message was automatically generated.
  

[jira] [Commented] (YARN-11222) [Federation] Add addToClusterNodeLabels, removeFromClusterNodeLabels REST APIs for Router

2023-02-08 Thread ASF GitHub Bot (Jira)


[ 
https://issues.apache.org/jira/browse/YARN-11222?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17686246#comment-17686246
 ] 

ASF GitHub Bot commented on YARN-11222:
---

hadoop-yetus commented on PR #5328:
URL: https://github.com/apache/hadoop/pull/5328#issuecomment-1423770788

   :confetti_ball: **+1 overall**
   
   
   
   
   
   
   | Vote | Subsystem | Runtime |  Logfile | Comment |
   |::|--:|:|::|:---:|
   | +0 :ok: |  reexec  |   1m 52s |  |  Docker mode activated.  |
    _ Prechecks _ |
   | +1 :green_heart: |  dupname  |   0m  0s |  |  No case conflicting files 
found.  |
   | +0 :ok: |  codespell  |   0m  0s |  |  codespell was not available.  |
   | +0 :ok: |  detsecrets  |   0m  0s |  |  detect-secrets was not available.  
|
   | +1 :green_heart: |  @author  |   0m  0s |  |  The patch does not contain 
any @author tags.  |
   | +1 :green_heart: |  test4tests  |   0m  0s |  |  The patch appears to 
include 3 new or modified test files.  |
    _ trunk Compile Tests _ |
   | +1 :green_heart: |  mvninstall  |  49m 43s |  |  trunk passed  |
   | +1 :green_heart: |  compile  |   0m 33s |  |  trunk passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  compile  |   0m 33s |  |  trunk passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  checkstyle  |   0m 28s |  |  trunk passed  |
   | +1 :green_heart: |  mvnsite  |   0m 35s |  |  trunk passed  |
   | +1 :green_heart: |  javadoc  |   0m 35s |  |  trunk passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  javadoc  |   0m 24s |  |  trunk passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  spotbugs  |   1m  9s |  |  trunk passed  |
   | +1 :green_heart: |  shadedclient  |  26m 15s |  |  branch has no errors 
when building and testing our client artifacts.  |
    _ Patch Compile Tests _ |
   | +1 :green_heart: |  mvninstall  |   0m 32s |  |  the patch passed  |
   | +1 :green_heart: |  compile  |   0m 29s |  |  the patch passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  javac  |   0m 29s |  |  the patch passed  |
   | +1 :green_heart: |  compile  |   0m 24s |  |  the patch passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  javac  |   0m 24s |  |  the patch passed  |
   | +1 :green_heart: |  blanks  |   0m  0s |  |  The patch has no blanks 
issues.  |
   | +1 :green_heart: |  checkstyle  |   0m 17s |  |  the patch passed  |
   | +1 :green_heart: |  mvnsite  |   0m 28s |  |  the patch passed  |
   | +1 :green_heart: |  javadoc  |   0m 23s |  |  the patch passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  javadoc  |   0m 21s |  |  the patch passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  spotbugs  |   1m  4s |  |  the patch passed  |
   | +1 :green_heart: |  shadedclient  |  26m 49s |  |  patch has no errors 
when building and testing our client artifacts.  |
    _ Other Tests _ |
   | +1 :green_heart: |  unit  |   0m 28s |  |  hadoop-yarn-server-router in 
the patch passed.  |
   | +1 :green_heart: |  asflicense  |   0m 34s |  |  The patch does not 
generate ASF License warnings.  |
   |  |   | 115m 17s |  |  |
   
   
   | Subsystem | Report/Notes |
   |--:|:-|
   | Docker | ClientAPI=1.42 ServerAPI=1.42 base: 
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5328/8/artifact/out/Dockerfile
 |
   | GITHUB PR | https://github.com/apache/hadoop/pull/5328 |
   | Optional Tests | dupname asflicense compile javac javadoc mvninstall 
mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets |
   | uname | Linux 92d13983f2cb 4.15.0-200-generic #211-Ubuntu SMP Thu Nov 24 
18:16:04 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux |
   | Build tool | maven |
   | Personality | dev-support/bin/hadoop.sh |
   | git revision | trunk / 75e7a42e133fb683b3b59d20d5f73cf9713fc18d |
   | Default Java | Private Build-1.8.0_352-8u352-ga-1~20.04-b08 |
   | Multi-JDK versions | 
/usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04 
/usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_352-8u352-ga-1~20.04-b08 |
   |  Test Results | 
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5328/8/testReport/ |
   | Max. process+thread count | 633 (vs. ulimit of 5500) |
   | modules | C: 
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router U: 
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router |
   | Console output | 
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5328/8/console |
   | versions | git=2.25.1 maven=3.6.3 spotbugs=4.2.2 |
   | Powered by | Apache Yetus 0.14.0 https://yetus.apache.org |
   
   
   This message was automatically generated.
  

[jira] [Commented] (YARN-11222) [Federation] Add addToClusterNodeLabels, removeFromClusterNodeLabels REST APIs for Router

2023-02-08 Thread ASF GitHub Bot (Jira)


[ 
https://issues.apache.org/jira/browse/YARN-11222?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17686194#comment-17686194
 ] 

ASF GitHub Bot commented on YARN-11222:
---

slfan1989 commented on code in PR #5328:
URL: https://github.com/apache/hadoop/pull/5328#discussion_r1101011482


##
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/webapp/FederationInterceptorREST.java:
##
@@ -1520,16 +1522,115 @@ public NodeLabelsInfo 
getClusterNodeLabels(HttpServletRequest hsr)
 throw new RuntimeException("getClusterNodeLabels Failed.");
   }
 
+  /**
+   * This method adds specific node labels for specific nodes, and it is
+   * reachable by using {@link RMWSConsts#ADD_NODE_LABELS}.
+   *
+   * @see ResourceManagerAdministrationProtocol#addToClusterNodeLabels
+   * @param newNodeLabels the node labels to add. It is a content param.
+   * @param hsr the servlet request
+   * @return Response containing the status code
+   * @throws Exception in case of bad request
+   */
   @Override
   public Response addToClusterNodeLabels(NodeLabelsInfo newNodeLabels,
   HttpServletRequest hsr) throws Exception {
-throw new NotImplementedException("Code is not implemented");
+
+if (newNodeLabels == null) {
+  routerMetrics.incrAddToClusterNodeLabelsFailedRetrieved();
+  throw new IllegalArgumentException("Parameter error, the newNodeLabels 
is null.");
+}
+
+List nodeLabelInfos = newNodeLabels.getNodeLabelsInfo();
+if (CollectionUtils.isEmpty(nodeLabelInfos)) {
+  routerMetrics.incrAddToClusterNodeLabelsFailedRetrieved();
+  throw new IllegalArgumentException("Parameter error, the nodeLabelsInfo 
is null or empty.");
+}
+
+try {
+  long startTime = clock.getTime();
+  Map subClustersActive = 
getActiveSubclusters();
+  final HttpServletRequest hsrCopy = clone(hsr);
+  Class[] argsClasses = new Class[]{NodeLabelsInfo.class, 
HttpServletRequest.class};
+  Object[] args = new Object[]{newNodeLabels, hsrCopy};
+  ClientMethod remoteMethod = new ClientMethod("addToClusterNodeLabels", 
argsClasses, args);
+  Map responseInfoMap =
+  invokeConcurrent(subClustersActive.values(), remoteMethod, 
Response.class);
+  StringBuffer buffer = new StringBuffer();
+  responseInfoMap.forEach((subClusterInfo, response) -> {
+SubClusterId subClusterId = subClusterInfo.getSubClusterId();
+if (response != null) {
+  buffer.append("SubCluster=" + subClusterId.getId() + ",SUCCESS#");
+} else {
+  buffer.append("SubCluster=" + subClusterId.getId() + ",FAILED#");
+}
+  });
+  long stopTime = clock.getTime();
+  routerMetrics.succeededAddToClusterNodeLabelsRetrieved((stopTime - 
startTime));
+  return Response.status(Status.OK).entity(buffer.toString()).build();
+} catch (NotFoundException e) {
+  routerMetrics.incrAddToClusterNodeLabelsFailedRetrieved();
+  RouterServerUtil.logAndThrowIOException("get all active sub cluster(s) 
error.", e);
+} catch (YarnException e) {
+  routerMetrics.incrAddToClusterNodeLabelsFailedRetrieved();
+  RouterServerUtil.logAndThrowIOException("addToClusterNodeLabels with 
yarn error.", e);
+}
+
+routerMetrics.incrAddToClusterNodeLabelsFailedRetrieved();
+throw new RuntimeException("addToClusterNodeLabels Failed.");
   }
 
+  /**
+   * This method removes all the node labels for specific nodes, and it is
+   * reachable by using {@link RMWSConsts#REMOVE_NODE_LABELS}.
+   *
+   * @see ResourceManagerAdministrationProtocol#removeFromClusterNodeLabels
+   * @param oldNodeLabels the node labels to remove. It is a QueryParam.
+   * @param hsr the servlet request
+   * @return Response containing the status code
+   * @throws Exception in case of bad request
+   */
   @Override
   public Response removeFromClusterNodeLabels(Set oldNodeLabels,
   HttpServletRequest hsr) throws Exception {
-throw new NotImplementedException("Code is not implemented");
+
+if (CollectionUtils.isEmpty(oldNodeLabels)) {
+  routerMetrics.incrRemoveFromClusterNodeLabelsFailedRetrieved();
+  throw new IllegalArgumentException("Parameter error, the oldNodeLabels 
is null or empty.");
+}
+
+try {
+  long startTime = clock.getTime();
+  Map subClustersActive = 
getActiveSubclusters();
+  final HttpServletRequest hsrCopy = clone(hsr);
+  Class[] argsClasses = new Class[]{Set.class, HttpServletRequest.class};
+  Object[] args = new Object[]{oldNodeLabels, hsrCopy};
+  ClientMethod remoteMethod =
+  new ClientMethod("removeFromClusterNodeLabels", argsClasses, args);
+  Map responseInfoMap =
+  invokeConcurrent(subClustersActive.values(), remoteMethod, 
Response.class);
+  StringBuffer buffer = new StringBuffer();
+  

[jira] [Commented] (YARN-11217) [Federation] Add dumpSchedulerLogs REST APIs for Router

2023-02-08 Thread ASF GitHub Bot (Jira)


[ 
https://issues.apache.org/jira/browse/YARN-11217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17686141#comment-17686141
 ] 

ASF GitHub Bot commented on YARN-11217:
---

slfan1989 commented on PR #5272:
URL: https://github.com/apache/hadoop/pull/5272#issuecomment-1423500988

   @goiri Thank you very much for helping to review the code! @pjfanning Thanks 
for your suggestion!




> [Federation] Add dumpSchedulerLogs REST APIs for Router
> ---
>
> Key: YARN-11217
> URL: https://issues.apache.org/jira/browse/YARN-11217
> Project: Hadoop YARN
>  Issue Type: Sub-task
>Affects Versions: 3.4.0, 3.3.4
>Reporter: Shilun Fan
>Assignee: Shilun Fan
>Priority: Major
>  Labels: pull-request-available
> Fix For: 3.4.0
>
>




--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org



[jira] [Commented] (YARN-11424) [Federation] Router AdminCLI Supports DeregisterSubCluster.

2023-02-08 Thread ASF GitHub Bot (Jira)


[ 
https://issues.apache.org/jira/browse/YARN-11424?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17686110#comment-17686110
 ] 

ASF GitHub Bot commented on YARN-11424:
---

hadoop-yetus commented on PR #5363:
URL: https://github.com/apache/hadoop/pull/5363#issuecomment-1423234322

   :broken_heart: **-1 overall**
   
   
   
   
   
   
   | Vote | Subsystem | Runtime |  Logfile | Comment |
   |::|--:|:|::|:---:|
   | +0 :ok: |  reexec  |   0m 57s |  |  Docker mode activated.  |
    _ Prechecks _ |
   | +1 :green_heart: |  dupname  |   0m  1s |  |  No case conflicting files 
found.  |
   | +0 :ok: |  codespell  |   0m  1s |  |  codespell was not available.  |
   | +0 :ok: |  detsecrets  |   0m  1s |  |  detect-secrets was not available.  
|
   | +0 :ok: |  buf  |   0m  1s |  |  buf was not available.  |
   | +0 :ok: |  buf  |   0m  1s |  |  buf was not available.  |
   | +0 :ok: |  xmllint  |   0m  1s |  |  xmllint was not available.  |
   | +1 :green_heart: |  @author  |   0m  0s |  |  The patch does not contain 
any @author tags.  |
   | +1 :green_heart: |  test4tests  |   0m  0s |  |  The patch appears to 
include 4 new or modified test files.  |
    _ trunk Compile Tests _ |
   | +0 :ok: |  mvndep  |  15m 51s |  |  Maven dependency ordering for branch  |
   | +1 :green_heart: |  mvninstall  |  31m 12s |  |  trunk passed  |
   | +1 :green_heart: |  compile  |   9m 46s |  |  trunk passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  compile  |   8m 36s |  |  trunk passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  checkstyle  |   1m 48s |  |  trunk passed  |
   | +1 :green_heart: |  mvnsite  |   6m 52s |  |  trunk passed  |
   | -1 :x: |  javadoc  |   1m  1s | 
[/branch-javadoc-hadoop-yarn-project_hadoop-yarn_hadoop-yarn-server_hadoop-yarn-server-resourcemanager-jdkUbuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04.txt](https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5363/2/artifact/out/branch-javadoc-hadoop-yarn-project_hadoop-yarn_hadoop-yarn-server_hadoop-yarn-server-resourcemanager-jdkUbuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04.txt)
 |  hadoop-yarn-server-resourcemanager in trunk failed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04.  |
   | -1 :x: |  javadoc  |   0m 43s | 
[/branch-javadoc-hadoop-yarn-project_hadoop-yarn_hadoop-yarn-client-jdkUbuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04.txt](https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5363/2/artifact/out/branch-javadoc-hadoop-yarn-project_hadoop-yarn_hadoop-yarn-client-jdkUbuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04.txt)
 |  hadoop-yarn-client in trunk failed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04.  |
   | +1 :green_heart: |  javadoc  |   5m 51s |  |  trunk passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  spotbugs  |  11m 36s |  |  trunk passed  |
   | +1 :green_heart: |  shadedclient  |  24m  0s |  |  branch has no errors 
when building and testing our client artifacts.  |
    _ Patch Compile Tests _ |
   | +0 :ok: |  mvndep  |   0m 28s |  |  Maven dependency ordering for patch  |
   | +1 :green_heart: |  mvninstall  |   5m  0s |  |  the patch passed  |
   | +1 :green_heart: |  compile  |   9m  7s |  |  the patch passed with JDK 
Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04  |
   | +1 :green_heart: |  cc  |   9m  7s |  |  the patch passed  |
   | -1 :x: |  javac  |   9m  7s | 
[/results-compile-javac-hadoop-yarn-project_hadoop-yarn-jdkUbuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04.txt](https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5363/2/artifact/out/results-compile-javac-hadoop-yarn-project_hadoop-yarn-jdkUbuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04.txt)
 |  
hadoop-yarn-project_hadoop-yarn-jdkUbuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04 
with JDK Ubuntu-11.0.17+8-post-Ubuntu-1ubuntu220.04 generated 1 new + 721 
unchanged - 0 fixed = 722 total (was 721)  |
   | +1 :green_heart: |  compile  |   8m 26s |  |  the patch passed with JDK 
Private Build-1.8.0_352-8u352-ga-1~20.04-b08  |
   | +1 :green_heart: |  cc  |   8m 26s |  |  the patch passed  |
   | -1 :x: |  javac  |   8m 26s | 
[/results-compile-javac-hadoop-yarn-project_hadoop-yarn-jdkPrivateBuild-1.8.0_352-8u352-ga-1~20.04-b08.txt](https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5363/2/artifact/out/results-compile-javac-hadoop-yarn-project_hadoop-yarn-jdkPrivateBuild-1.8.0_352-8u352-ga-1~20.04-b08.txt)
 |  
hadoop-yarn-project_hadoop-yarn-jdkPrivateBuild-1.8.0_352-8u352-ga-1~20.04-b08 
with JDK Private Build-1.8.0_352-8u352-ga-1~20.04-b08 generated 3 new + 635 
unchanged - 3 fixed = 638 total (was 638)  |
   | +1 :green_heart: |  blanks  |   0m  0s |  |  The patch has no blanks 
issues.  |
   | +1 :green_heart: |  checkstyle  |   1m 39s |  |  
hadoop-yarn-project/hadoop-yarn: The patch generated 0 new + 238 unchanged - 1 

[jira] [Resolved] (YARN-11217) [Federation] Add dumpSchedulerLogs REST APIs for Router

2023-02-08 Thread Jira


 [ 
https://issues.apache.org/jira/browse/YARN-11217?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Íñigo Goiri resolved YARN-11217.

Fix Version/s: 3.4.0
 Hadoop Flags: Reviewed
   Resolution: Fixed

> [Federation] Add dumpSchedulerLogs REST APIs for Router
> ---
>
> Key: YARN-11217
> URL: https://issues.apache.org/jira/browse/YARN-11217
> Project: Hadoop YARN
>  Issue Type: Sub-task
>Affects Versions: 3.4.0, 3.3.4
>Reporter: Shilun Fan
>Assignee: Shilun Fan
>Priority: Major
>  Labels: pull-request-available
> Fix For: 3.4.0
>
>




--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org



[jira] [Commented] (YARN-11217) [Federation] Add dumpSchedulerLogs REST APIs for Router

2023-02-08 Thread ASF GitHub Bot (Jira)


[ 
https://issues.apache.org/jira/browse/YARN-11217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17686086#comment-17686086
 ] 

ASF GitHub Bot commented on YARN-11217:
---

goiri merged PR #5272:
URL: https://github.com/apache/hadoop/pull/5272




> [Federation] Add dumpSchedulerLogs REST APIs for Router
> ---
>
> Key: YARN-11217
> URL: https://issues.apache.org/jira/browse/YARN-11217
> Project: Hadoop YARN
>  Issue Type: Sub-task
>Affects Versions: 3.4.0, 3.3.4
>Reporter: Shilun Fan
>Assignee: Shilun Fan
>Priority: Major
>  Labels: pull-request-available
>




--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org



[jira] [Commented] (YARN-11424) [Federation] Router AdminCLI Supports DeregisterSubCluster.

2023-02-08 Thread ASF GitHub Bot (Jira)


[ 
https://issues.apache.org/jira/browse/YARN-11424?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17685921#comment-17685921
 ] 

ASF GitHub Bot commented on YARN-11424:
---

slfan1989 commented on code in PR #5363:
URL: https://github.com/apache/hadoop/pull/5363#discussion_r1100223667


##
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/conf/YarnConfiguration.java:
##
@@ -4299,6 +4299,11 @@ public static boolean isAclEnabled(Configuration conf) {
   ROUTER_PREFIX + "interceptor.allow-partial-result.enable";
   public static final boolean 
DEFAULT_ROUTER_INTERCEPTOR_ALLOW_PARTIAL_RESULT_ENABLED = false;
 
+  /** Subcluster timeout allowed by Router.  **/
+  public static final String ROUTER_SUBCLUSTER_EXPIRATION_TIME =
+  ROUTER_PREFIX + "subcluster.heartbeat.expiration.time";
+  public static final long DEFAULT_ROUTER_SUBCLUSTER_EXPIRATION_TIME = 180;

Review Comment:
   Thank you very much for helping to review the code, I will modify the code.



##
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/cli/RouterCLI.java:
##
@@ -37,12 +66,48 @@ public RouterCLI(Configuration conf) {
 super(conf);
   }
 
+  private static void buildHelpMsg(String cmd, StringBuilder builder) {
+UsageInfo usageInfo = ADMIN_USAGE.get(cmd);
+if (usageInfo == null) {
+  return;
+}
+
+if (usageInfo.args != null) {
+  String space = (usageInfo.args == "") ? "" : " ";
+  builder.append("   " + cmd + space + usageInfo.args + ": "
+  + usageInfo.help);
+} else {
+  builder.append("   " + cmd + ": " + usageInfo.help);
+}
+  }
+
+  private static void buildIndividualUsageMsg(String cmd, StringBuilder 
builder) {
+UsageInfo usageInfo = ADMIN_USAGE.get(cmd);
+if (usageInfo == null) {
+  return;
+}
+if (usageInfo.args == null) {
+  builder.append("Usage: routeradmin [" + cmd + "]\n");

Review Comment:
   I will modify the code.





> [Federation] Router AdminCLI Supports DeregisterSubCluster.
> ---
>
> Key: YARN-11424
> URL: https://issues.apache.org/jira/browse/YARN-11424
> Project: Hadoop YARN
>  Issue Type: Sub-task
>  Components: federation
>Affects Versions: 3.4.0
>Reporter: Shilun Fan
>Assignee: Shilun Fan
>Priority: Major
>  Labels: pull-request-available
>
> Router provides commands for Deregister SubCluster.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org



[jira] [Commented] (YARN-11424) [Federation] Router AdminCLI Supports DeregisterSubCluster.

2023-02-08 Thread ASF GitHub Bot (Jira)


[ 
https://issues.apache.org/jira/browse/YARN-11424?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17685923#comment-17685923
 ] 

ASF GitHub Bot commented on YARN-11424:
---

slfan1989 commented on code in PR #5363:
URL: https://github.com/apache/hadoop/pull/5363#discussion_r1100224341


##
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/federation/store/records/SubClusterState.java:
##
@@ -55,6 +55,10 @@ public boolean isUnusable() {
 return (this != SC_RUNNING && this != SC_NEW);
   }
 
+  public boolean isUsable() {
+return !isUnusable();

Review Comment:
   I will fix it.





> [Federation] Router AdminCLI Supports DeregisterSubCluster.
> ---
>
> Key: YARN-11424
> URL: https://issues.apache.org/jira/browse/YARN-11424
> Project: Hadoop YARN
>  Issue Type: Sub-task
>  Components: federation
>Affects Versions: 3.4.0
>Reporter: Shilun Fan
>Assignee: Shilun Fan
>Priority: Major
>  Labels: pull-request-available
>
> Router provides commands for Deregister SubCluster.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org