hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Varun Saxena (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-3916) DrainDispatcher#await should wait till event has been completely handled
Date Mon, 13 Jul 2015 06:55:05 GMT

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

Varun Saxena commented on YARN-3916:
------------------------------------

I thought of this first.
But issue here is that LinkedBlockingQueue#take is a blocking queue. It wont return from the
call if there are no pending events.
If I set the flag before this call, it is possible that we are stuck forever there.
If I set it afterwards there can be a minor race wherein event queue may have taken from queue
and made it empty but not updated the flag to true. In this case, we may wrongly judge that
no events are being processed.

> DrainDispatcher#await should wait till event has been completely handled
> ------------------------------------------------------------------------
>
>                 Key: YARN-3916
>                 URL: https://issues.apache.org/jira/browse/YARN-3916
>             Project: Hadoop YARN
>          Issue Type: Bug
>    Affects Versions: 2.7.0
>            Reporter: Varun Saxena
>            Assignee: Varun Saxena
>            Priority: Critical
>         Attachments: YARN-3916.01.patch, YARN-3916.02.patch
>
>
> DrainDispatcher#await should wait till event has been completely handled.
> Currently it only checks for whether event queue has become empty.
> And in many tests we directly check for a state to be changed after calling await.
> Sometimes, the states do not change by the time we check them as event has not been completely
handled.
> *This is causing test failures* such as YARN-3909 and YARN-3910 and may cause other test
failures as well.



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

Mime
View raw message