From c89d462761a3aa688dc84159eed5cfbd327f23a2 Mon Sep 17 00:00:00 2001 From: Rohith Sharma K S Date: Tue, 6 Sep 2016 14:09:45 +0530 Subject: [PATCH] YARN-5608. TestAMRMClient.setup() fails with ArrayOutOfBoundsException. Contributed by Daniel Templeton. (cherry picked from commit f9557127b3660e138cab8d9535a589677809384a) --- .../apache/hadoop/yarn/client/api/impl/TestAMRMClient.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/test/java/org/apache/hadoop/yarn/client/api/impl/TestAMRMClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/test/java/org/apache/hadoop/yarn/client/api/impl/TestAMRMClient.java index 79d1c67a532..314ca0a7aa9 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/test/java/org/apache/hadoop/yarn/client/api/impl/TestAMRMClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/test/java/org/apache/hadoop/yarn/client/api/impl/TestAMRMClient.java @@ -143,8 +143,13 @@ public class TestAMRMClient { yarnClient.start(); // get node info + assertTrue("All node managers did not connect to the RM within the " + + "allotted 5-second timeout", + yarnCluster.waitForNodeManagersToConnect(5000L)); nodeReports = yarnClient.getNodeReports(NodeState.RUNNING); - + assertEquals("Not all node managers were reported running", + nodeCount, nodeReports.size()); + priority = Priority.newInstance(1); priority2 = Priority.newInstance(2); capability = Resource.newInstance(1024, 1);