[ https://issues.apache.org/jira/browse/YARN-1425?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13827075#comment-13827075 ]
Omkar Vinit Joshi commented on YARN-1425: ----------------------------------------- just discovered MockRM.waitForState(appAttempt, RMAppAttemptState)... simple ignores the passed in application attempt and always considers current application attempt. Fixing it. *RMAppAttempt attempt = app.getCurrentAppAttempt();* {code} public void waitForState(ApplicationAttemptId attemptId, RMAppAttemptState finalState) throws Exception { RMApp app = getRMContext().getRMApps().get(attemptId.getApplicationId()); Assert.assertNotNull("app shouldn't be null", app); RMAppAttempt attempt = app.getCurrentAppAttempt(); int timeoutSecs = 0; while (!finalState.equals(attempt.getAppAttemptState()) && timeoutSecs++ < 40) { System.out.println("AppAttempt : " + attemptId + " State is : " + attempt.getAppAttemptState() + " Waiting for state : " + finalState); Thread.sleep(1000); } System.out.println("Attempt State is : " + attempt.getAppAttemptState()); Assert.assertEquals("Attempt state is not correct (timedout)", finalState, attempt.getAppAttemptState()); } {code} > TestRMRestart is failing on trunk > --------------------------------- > > Key: YARN-1425 > URL: https://issues.apache.org/jira/browse/YARN-1425 > Project: Hadoop YARN > Issue Type: Bug > Reporter: Omkar Vinit Joshi > Assignee: Omkar Vinit Joshi > Attachments: error.log > > > TestRMRestart is failing on trunk. Fixing it. -- This message was sent by Atlassian JIRA (v6.1#6144)