hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Konstantin Boudnik (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HDFS-1310) TestFileConcurrentReader fails
Date Mon, 23 Aug 2010 23:27:16 GMT

    [ https://issues.apache.org/jira/browse/HDFS-1310?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12901666#action_12901666

Konstantin Boudnik commented on HDFS-1310:

Using sleep intervals in tests is suboptimal at best; using them to fix race-conditioned tests
is pretty bad, I'd say.
Besides, the test is JUnit v3 - an unsupported old version of the framework. We are using
4.5 at the moment. Last but not least, calling {{super.tearDown()}} doesn't make _any_ sense
at all because this is an empty method of the {{TestCase}} class.

Loops like this
    while (!done) {
      try {
      } catch (InterruptedException e) {
      done = true;
      BlockLocation[] locations = fileSys.getFileBlockLocations(
        fileSys.getFileStatus(name), 0, blockSize);
      if (locations.length < 1) {
        done = false;
are begging for troubles and potential timeouts. There's no guarantee that its condition will
ever be satisfied.

I'd say the test needs to be refactored to JUnit v4.5 and then re-evaluated to see if the
timeouts still occur.

> TestFileConcurrentReader fails
> ------------------------------
>                 Key: HDFS-1310
>                 URL: https://issues.apache.org/jira/browse/HDFS-1310
>             Project: Hadoop HDFS
>          Issue Type: Test
>    Affects Versions: 0.22.0
>            Reporter: Suresh Srinivas
> For details of test failure see http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h2.grid.sp2.yahoo.net/218/testReport/

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message