[ https://issues.apache.org/jira/browse/YARN-7663?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16312700#comment-16312700 ]
lujie edited comment on YARN-7663 at 1/5/18 8:28 AM: ----------------------------------------------------- Hi: I have moved the method that performs assert to new test just as [#Jason Lowe] suggest. But I still feel uncertain about the TODO that exists in RMAppImpl handle foo when I add onInvalidStateTransition. Below is the code: {code:java} try { /* keep the master in sync with the state machine */ this.stateMachine.doTransition(event.getType(), event); } catch (InvalidStateTransitionException e) { LOG.error("App: " + appID + " can't handle this event at current state", e); onInvalidStateTransition(event.getType(), oldState); TODO fail the application on the failed transition } {code} The TODO already exists in system for a long time, if this TODO is meaningless, it should be deleted. If it is really needed to implement, I think the implementation can be placed in new added foo(onInvalidStateTransition). was (Author: xiaoheipangzi): Hi: I have moved the method that performs assert to new test just as [#Jason Lowe] suggest. But I still feel uncertain about the TODO that exists in RMAppImpl handle foo when I add onInvalidStateTransition. Below is the code: {code:java} try { /* keep the master in sync with the state machine */ this.stateMachine.doTransition(event.getType(), event); } catch (InvalidStateTransitionException e) { LOG.error("App: " + appID + " can't handle this event at current state", e); onInvalidStateTransition(event.getType(), oldState); {color:red}/* TODO fail the application on the failed transition */{color} } {code} The TODO already exists in system for a long time, if this TODO is meaningless, it should be deleted. If it is really needed to implement, I think the implementation can be placed in new added foo(onInvalidStateTransition). > RMAppImpl:Invalid event: START at KILLED > ---------------------------------------- > > Key: YARN-7663 > URL: https://issues.apache.org/jira/browse/YARN-7663 > Project: Hadoop YARN > Issue Type: Bug > Components: resourcemanager > Affects Versions: 2.8.0 > Reporter: lujie > Assignee: lujie > Priority: Minor > Labels: patch > Attachments: YARN-7663_1.patch, YARN-7663_2.patch, YARN-7663_3.patch, > YARN-7663_4.patch > > > Send kill to application, the RM log shows: > {code:java} > org.apache.hadoop.yarn.state.InvalidStateTransitionException: Invalid event: > START at KILLED > at > org.apache.hadoop.yarn.state.StateMachineFactory.doTransition(StateMachineFactory.java:305) > at > org.apache.hadoop.yarn.state.StateMachineFactory.access$300(StateMachineFactory.java:46) > at > org.apache.hadoop.yarn.state.StateMachineFactory$InternalStateMachine.doTransition(StateMachineFactory.java:448) > at > org.apache.hadoop.yarn.server.resourcemanager.rmapp.RMAppImpl.handle(RMAppImpl.java:805) > at > org.apache.hadoop.yarn.server.resourcemanager.rmapp.RMAppImpl.handle(RMAppImpl.java:116) > at > org.apache.hadoop.yarn.server.resourcemanager.ResourceManager$ApplicationEventDispatcher.handle(ResourceManager.java:901) > at > org.apache.hadoop.yarn.server.resourcemanager.ResourceManager$ApplicationEventDispatcher.handle(ResourceManager.java:885) > at > org.apache.hadoop.yarn.event.AsyncDispatcher.dispatch(AsyncDispatcher.java:184) > at > org.apache.hadoop.yarn.event.AsyncDispatcher$1.run(AsyncDispatcher.java:110) > at java.lang.Thread.run(Thread.java:745) > {code} > if insert sleep before where the START event was created, this bug will > deterministically reproduce. -- This message was sent by Atlassian JIRA (v6.4.14#64029) --------------------------------------------------------------------- To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org