[
https://issues.apache.org/jira/browse/HADOOP-12715?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Xiao Chen updated HADOOP-12715:
-------------------------------
Attachment: HADOOP-12715.01.patch
Reason for the failure is because {{ValueQueue}} has an async filling thread.
There's a race between the async filling after {{getAtMost(10)}}, and the sync
filling of {{getAtMost(19)}}.
Patch 1 enhanced the test to first check the async {{getAtMost(10)}}, then
check the sync {{getAtMost(19)}}. Also added timeout to all tests in this
class, and enhanced the asserts to have a message.
> TestValueQueue#testgetAtMostPolicyALL fails intermittently
> ----------------------------------------------------------
>
> Key: HADOOP-12715
> URL: https://issues.apache.org/jira/browse/HADOOP-12715
> Project: Hadoop Common
> Issue Type: Test
> Reporter: Xiao Chen
> Assignee: Xiao Chen
> Attachments: HADOOP-12715.01.patch
>
>
> The test fails intermittently with the following error.
> Error Message
> {noformat}
> expected:<19> but was:<10>
> {noformat}
> Stacktrace
> {noformat}
> java.lang.AssertionError: expected:<19> but was:<10>
> at org.junit.Assert.fail(Assert.java:88)
> at org.junit.Assert.failNotEquals(Assert.java:743)
> at org.junit.Assert.assertEquals(Assert.java:118)
> at org.junit.Assert.assertEquals(Assert.java:555)
> at org.junit.Assert.assertEquals(Assert.java:542)
> at
> org.apache.hadoop.crypto.key.TestValueQueue.testgetAtMostPolicyALL(TestValueQueue.java:149)
> {noformat}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)