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

Appy commented on HBASE-16775:
------------------------------

yeah, gave it a bunch of time and now I am of the opinion that this test 
doesn't make sense because it's not testing any feature of 'ExportSnapshot' 
tool. It's basically trying to test if mapreduce frameworks retires a mapper if 
the "mapreduce.map.maxattempts" is set, nothing HBasey!

Also not that the test itself is wrong. It injects failure only some times (3% 
probability for each mapper). So many runs don't even get the failure injected, 
and those are precisely the only ones where it passes.

{noformat}
      if (testFailures) {
        if (context.getConfiguration().getBoolean(CONF_TEST_RETRY, false)) {
          if (random == null) {
            random = new Random();
          }

          // FLAKY-TEST-WARN: lower is better, we can get some runs without the
          // retry, but at least we reduce the number of test failures due to
          // this test exception from the same map task.
          if (random.nextFloat() < 0.03) {
            throw new IOException("TEST RETRY FAILURE: Unable to copy input=" + 
inputInfo
                                  + " time=" + System.currentTimeMillis());
          }
        } else {
          context.getCounter(Counter.COPY_FAILED).increment(1);
          throw new IOException("TEST FAILURE: Unable to copy input=" + 
inputInfo);
        }
      }
    }
{noformat}

> Flakey test with TestExportSnapshot#testExportRetry and 
> TestMobExportSnapshot#testExportRetry 
> ----------------------------------------------------------------------------------------------
>
>                 Key: HBASE-16775
>                 URL: https://issues.apache.org/jira/browse/HBASE-16775
>             Project: HBase
>          Issue Type: Bug
>    Affects Versions: 2.0.0
>            Reporter: huaxiang sun
>            Assignee: huaxiang sun
>
> The root cause is that conf.setInt("mapreduce.map.maxattempts", 10) is not 
> taken by the mapper job, so the retry is actually 0. Debugging to see why 
> this is the case.



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

Reply via email to