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

sandflee commented on YARN-5375:
--------------------------------

there still had a very little chance that events are left in eventQueue event 
if drainEvents returned. Thought not related to this issue, if drainEvents 
could granted that all event are processed completed, we could use drainEvents 
in waitForState to replace wait-sleep way. like
{code}
waitForState(app, state) {
   drainEvents()
   assert.equals(app.state, state)
}
{code}
this may reduce the test times, and wondered whether we should do that.

> invoke MockRM#drainEvents implicitly in MockRM methods to reduce test failures
> ------------------------------------------------------------------------------
>
>                 Key: YARN-5375
>                 URL: https://issues.apache.org/jira/browse/YARN-5375
>             Project: Hadoop YARN
>          Issue Type: Improvement
>            Reporter: sandflee
>            Assignee: sandflee
>         Attachments: YARN-5375.01.patch
>
>
> seen many test failures related to RMApp/RMAppattempt comes to some state but 
> some event are not processed in rm event queue or scheduler event queue, 
> cause test failure, seems we could implicitly invokes drainEvents(should also 
> drain sheduler event) in some mockRM method like waitForState



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to