You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/06/19 07:59:00 UTC

[jira] [Commented] (FLINK-6945) TaskCancelAsyncProducerConsumerITCase.testCancelAsyncProducerAndConsumer instable test case

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

ASF GitHub Bot commented on FLINK-6945:
---------------------------------------

GitHub user tillrohrmann opened a pull request:

    https://github.com/apache/flink/pull/4139

    [FLINK-6945] Fix TaskCancelAsyncProducerConsumerITCase by removing race condition

    The TaskCacnelAsyncProducerConsumerITCase#testCancelAsyncProducerAndConsumer test case
    sometimes failed with a NPE because of a race condition. The problem was that some
    invokables set static fields which are checked in the main thread. Since we checked
    the wrong field, the one for the consumer, after making sure that the producer
    is running, this could lead to a race condition if the consumer wasn't running yet.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/tillrohrmann/flink fixTaskCancelAsyncProducerConsumerITCase

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/4139.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #4139
    
----
commit a1356b951326d7f40a05eb61034a46b941d18faa
Author: Till Rohrmann <tr...@apache.org>
Date:   2017-06-19T07:54:35Z

    [FLINK-6945] Fix TaskCancelAsyncProducerConsumerITCase by removing race condition
    
    The TaskCacnelAsyncProducerConsumerITCase#testCancelAsyncProducerAndConsumer test case
    sometimes failed with a NPE because of a race condition. The problem was that some
    invokables set static fields which are checked in the main thread. Since we checked
    the wrong field, the one for the consumer, after making sure that the producer
    is running, this could lead to a race condition if the consumer wasn't running yet.

----


> TaskCancelAsyncProducerConsumerITCase.testCancelAsyncProducerAndConsumer instable test case
> -------------------------------------------------------------------------------------------
>
>                 Key: FLINK-6945
>                 URL: https://issues.apache.org/jira/browse/FLINK-6945
>             Project: Flink
>          Issue Type: Bug
>          Components: Tests
>    Affects Versions: 1.3.1, 1.4.0
>            Reporter: Till Rohrmann
>            Assignee: Till Rohrmann
>            Priority: Critical
>             Fix For: 1.4.0, 1.3.2
>
>
> The test case {{TaskCancelAsyncProducerConsumerITCase.testCancelAsyncProducerAndConsumer}} sometimes fails with a {{NullPointerException}} [1]. The reason is that contains a race condition between a check and the initialization logic of a {{Thread}}.
> [1] https://s3.amazonaws.com/archive.travis-ci.org/jobs/243036022/log.txt



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)