[
https://issues.apache.org/jira/browse/YARN-11420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17789044#comment-17789044
]
ASF GitHub Bot commented on YARN-11420:
---------------------------------------
susheel-gupta commented on code in PR #5317:
URL: https://github.com/apache/hadoop/pull/5317#discussion_r1403154800
##########
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-tests/src/test/java/org/apache/hadoop/yarn/server/MiniYARNCluster.java:
##########
@@ -456,6 +456,19 @@ public int getActiveRMIndex() {
return -1;
}
+ /**
+ * Stopping MiniYarnCluster can take more than 30 seconds and it's a
blocking operation so it blocks test execution,
+ * so to prevent that we can stop the cluster asynchronously,
+ * that can ultimately save test execution time.
+ * @param owner the Test class that owns the instance of MiniYarnCluster
+ */
+ public void asyncStop(Object owner) {
Review Comment:
Each mini cluster is taking 40-55 secs to be stopped. As per your comment
and the code, async is an inappropriate choice so updated with sync stopping
of Mini cluster.
Thanks @tomicooler for reviewing.
> Stabilize TestNMClient
> ----------------------
>
> Key: YARN-11420
> URL: https://issues.apache.org/jira/browse/YARN-11420
> Project: Hadoop YARN
> Issue Type: Improvement
> Components: yarn
> Affects Versions: 3.4.0
> Reporter: Bence Kosztolnik
> Assignee: Susheel Gupta
> Priority: Major
> Labels: pull-request-available
>
> The TestNMClient test methods can stuck if the test container fails, while
> the test is expecting it running state. This can happen for example if the
> container fails due low memory. To fix this the test should tolerate some
> failure like this.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]