Uploaded image for project: 'Pig'
  1. Pig
  2. PIG-4086

Fix Orc e2e tests for tez

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.14.0
    • impl
    • None
    • Reviewed

    Description

      All Orc e2e tests fail on tez.

      There are two issue:
      1. hivelibdir etc is not set in tez.conf
      2. OrcStorage produce empty output file

      Digging into #2, the problem is in this code in PigProcessor:

                      if (fileOutput.isCommitRequired()) {
                          fileOutput.commit();
                      }
      

      fileOutput.commit() invokes both RecordWriter.close() and committer.commitTask(). However, OrcNewOutputFormate will generate output file only after RecordWriter.close (if the output file is small), fileOutput.isCommitRequired will not detect this file, thus skip fileOutput.commit().

      Changing the code to invoke fileOutput.close explicitly fix the issue. fileOutput.commit will invoke close again, but there is no side effect since close will check if it has been already called.

      Attachments

        1. PIG-4086-3.patch
          1 kB
          Daniel Dai
        2. PIG-4086-2.patch
          1 kB
          Daniel Dai
        3. PIG-4086-1.patch
          1 kB
          Daniel Dai

        Issue Links

          Activity

            People

              daijy Daniel Dai
              daijy Daniel Dai
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: