Hadoop Map/Reduce
  1. Hadoop Map/Reduce
  2. MAPREDUCE-2032

TestJobOutputCommitter fails in ant test run

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.21.1, 0.22.0
    • Component/s: task
    • Labels:
      None
    • Hadoop Flags:
      Reviewed
    • Release Note:
      Clears a problem that {{TestJobCleanup}} leaves behind files that cause {{TestJobOutputCommitter}} to error out.

      Description

      TestJobOutputCommitter fails in a "ant test" run with following exception :

      Output directory /home/amarsri/mapred/build/test/data/test-job-cleanup/output-2 already exists
      org.apache.hadoop.fs.FileAlreadyExistsException: Output directory /home/amarsri/mapred/build/test/data/test-job-cleanup/output-2 already exists
              at org.apache.hadoop.mapreduce.lib.output.FileOutputFormat.checkOutputSpecs(FileOutputFormat.java:141)
              at org.apache.hadoop.mapreduce.JobSubmitter.checkSpecs(JobSubmitter.java:391)
              at org.apache.hadoop.mapreduce.JobSubmitter.submitJobInternal(JobSubmitter.java:350)
              at org.apache.hadoop.mapreduce.Job$2.run(Job.java:1037)
              at org.apache.hadoop.mapreduce.Job$2.run(Job.java:1034)
              at java.security.AccessController.doPrivileged(Native Method)
              at javax.security.auth.Subject.doAs(Subject.java:396)
              at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1093)
              at org.apache.hadoop.mapreduce.Job.submit(Job.java:1034)
              at org.apache.hadoop.mapreduce.lib.output.TestJobOutputCommitter.testKilledJob(TestJobOutputCommitter.java:192)
              at org.apache.hadoop.mapreduce.lib.output.TestJobOutputCommitter.testDefaultCleanupAndAbort(TestJobOutputCommitter.java:232)
      

      But it passes when it is run individually.

        Issue Links

          Activity

          Hide
          Hudson added a comment -

          Integrated in Hadoop-Mapreduce-trunk-Commit #523 (See https://hudson.apache.org/hudson/job/Hadoop-Mapreduce-trunk-Commit/523/)

          Show
          Hudson added a comment - Integrated in Hadoop-Mapreduce-trunk-Commit #523 (See https://hudson.apache.org/hudson/job/Hadoop-Mapreduce-trunk-Commit/523/ )
          Hide
          Amareshwari Sriramadasu added a comment -

          Committed the fix to branch 0.21 as well.

          Show
          Amareshwari Sriramadasu added a comment - Committed the fix to branch 0.21 as well.
          Hide
          Amareshwari Sriramadasu added a comment -

          I just committed this. Thanks Dick !

          Show
          Amareshwari Sriramadasu added a comment - I just committed this. Thanks Dick !
          Hide
          Amareshwari Sriramadasu added a comment -

          +1 for the patch.
          Test passes now during ant test run. Will commit this.

          Show
          Amareshwari Sriramadasu added a comment - +1 for the patch. Test passes now during ant test run. Will commit this.
          Hide
          Dick King added a comment -

          I honored the request made in a previous comment

          Show
          Dick King added a comment - I honored the request made in a previous comment
          Hide
          Dick King added a comment -

          I'll look into that when me back from vacation.

          Show
          Dick King added a comment - I'll look into that when me back from vacation.
          Hide
          Amareshwari Sriramadasu added a comment -

          Can you delete the TEST_ROOT_DIR in tearDown, instead of deleting output directory in every testcase ?

          Show
          Amareshwari Sriramadasu added a comment - Can you delete the TEST_ROOT_DIR in tearDown, instead of deleting output directory in every testcase ?
          Hide
          Giridharan Kesavan added a comment -

          re-submitting for hudson

          Show
          Giridharan Kesavan added a comment - re-submitting for hudson
          Hide
          Dick King added a comment -

          I found the problem.

          TestJobCleanup leaves behind files that cause TestJobOutputCommitter to error out.

          This patch, which I ripped out of MAPREDUCE-323 , solves this bug. If it gets committed, I'll strip it from MAPREDUCE-323 .

          Show
          Dick King added a comment - I found the problem. TestJobCleanup leaves behind files that cause TestJobOutputCommitter to error out. This patch, which I ripped out of MAPREDUCE-323 , solves this bug. If it gets committed, I'll strip it from MAPREDUCE-323 .
          Hide
          Dick King added a comment -

          I assume we have a convention that tests don't leave junk behind, as opposed to having a convention that tests clean out all possible junk before they start.

          Show
          Dick King added a comment - I assume we have a convention that tests don't leave junk behind, as opposed to having a convention that tests clean out all possible junk before they start.

            People

            • Assignee:
              Dick King
              Reporter:
              Amareshwari Sriramadasu
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development