You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Wei-Chiu Chuang (JIRA)" <ji...@apache.org> on 2015/12/16 21:46:46 UTC

[jira] [Updated] (HDFS-9565) TestDistributedFileSystem.testLocatedFileStatusStorageIdsTypes is flaky due to race condition

     [ https://issues.apache.org/jira/browse/HDFS-9565?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Wei-Chiu Chuang updated HDFS-9565:
----------------------------------
    Summary: TestDistributedFileSystem.testLocatedFileStatusStorageIdsTypes is flaky due to race condition  (was: TestDistributedFileSystem.testLocatedFileStatusStorageIdsTypes is flaky)

> TestDistributedFileSystem.testLocatedFileStatusStorageIdsTypes is flaky due to race condition
> ---------------------------------------------------------------------------------------------
>
>                 Key: HDFS-9565
>                 URL: https://issues.apache.org/jira/browse/HDFS-9565
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: fs, test
>    Affects Versions: 3.0.0
>         Environment: Jenkins
>            Reporter: Wei-Chiu Chuang
>            Assignee: Wei-Chiu Chuang
>            Priority: Minor
>         Attachments: HDFS-9565.001.patch
>
>
> TestDistributedFileSystem.testLocatedFileStatusStorageIdsTypes occasionally fails with the following error:
> https://builds.apache.org/job/Hadoop-Hdfs-trunk-Java8/699/testReport/org.apache.hadoop.hdfs/TestDistributedFileSystem/testLocatedFileStatusStorageIdsTypes/
> {noformat}
> FAILED:  org.apache.hadoop.hdfs.TestDistributedFileSystem.testLocatedFileStatusStorageIdsTypes
> Error Message:
> Unexpected num storage ids expected:<2> but was:<1>
> Stack Trace:
> java.lang.AssertionError: Unexpected num storage ids expected:<2> but was:<1>
> 	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.apache.hadoop.hdfs.TestDistributedFileSystem.testLocatedFileStatusStorageIdsTypes(TestDistributedFileSystem.java:855)
> {noformat}
> It appears that this test failed due to race condition: it does not wait for the file replication to finish, before checking the file's status. 
> This flaky test can be fixed by using DFSTestUtil.waitForReplication()



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