Hive
  1. Hive
  2. HIVE-6328

Hive script should not overwrite AUX_CLASSPATH with HIVE_AUX_JARS_PATH if the latter is set

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.8.0, 0.9.0, 0.10.0, 0.12.0
    • Fix Version/s: 0.13.0
    • Component/s: None
    • Labels:
      None

      Description

      Hive script (bin/hive) replaces the value of AUX_CLASSPATH with the value of HIVE_AUX_JARS_PATH if HIVE_AUX_JARS_PATH is defined. This is not desirable because user uses the former to include additional classes when starting hive, while using the latter to specify additional jars that are needed to run MR jobs. The problem can be demonstrated with the script snippet:

      elif [ "${HIVE_AUX_JARS_PATH}" != "" ]; then
        HIVE_AUX_JARS_PATH=`echo $HIVE_AUX_JARS_PATH | sed 's/,/:/g'`
        if $cygwin; then
            HIVE_AUX_JARS_PATH=`cygpath -p -w "$HIVE_AUX_JARS_PATH"`
            HIVE_AUX_JARS_PATH=`echo $HIVE_AUX_JARS_PATH | sed 's/;/,/g'`
        fi
        AUX_CLASSPATH=${HIVE_AUX_JARS_PATH}
        AUX_PARAM="file://$(echo ${HIVE_AUX_JARS_PATH} | sed 's/:/,file:\/\//g')"
      fi
      

      AUX_CLASSPATH should be respected regardless whether HIVE_AUX_JARS_PATH is defined.

      1. HIVE-6328.patch
        0.5 kB
        Xuefu Zhang

        Issue Links

          Activity

          Hide
          Lefty Leverenz added a comment -

          Has anyone updated the wiki with information about this jira & related jiras (HIVE-2269, HIVE-3978, HIVE-5363, HIVE-5410)?

          Show
          Lefty Leverenz added a comment - Has anyone updated the wiki with information about this jira & related jiras ( HIVE-2269 , HIVE-3978 , HIVE-5363 , HIVE-5410 )?
          Lefty Leverenz made changes -
          Link This issue is related to HIVE-5410 [ HIVE-5410 ]
          Xuefu Zhang made changes -
          Status Patch Available [ 10002 ] Resolved [ 5 ]
          Fix Version/s 0.13.0 [ 12324986 ]
          Resolution Fixed [ 1 ]
          Hide
          Xuefu Zhang added a comment -

          Patch committed to trunk. Thanks to Prasad for the review.

          Show
          Xuefu Zhang added a comment - Patch committed to trunk. Thanks to Prasad for the review.
          Hide
          Prasad Mujumdar added a comment -

          +1

          Looks fine to me. Thanks for taking care of the issue.

          Show
          Prasad Mujumdar added a comment - +1 Looks fine to me. Thanks for taking care of the issue.
          Hide
          Xuefu Zhang added a comment -

          The above test failure doesn't appear related to the changes here. Manually run that test passed. Patch is good for review.

          Show
          Xuefu Zhang added a comment - The above test failure doesn't appear related to the changes here. Manually run that test passed. Patch is good for review.
          Hide
          Hive QA added a comment -

          Overall: -1 at least one tests failed

          Here are the results of testing the latest attachment:
          https://issues.apache.org/jira/secure/attachment/12625783/HIVE-6328.patch

          ERROR: -1 due to 1 failed/errored test(s), 4972 tests executed
          Failed tests:

          org.apache.hadoop.hive.cli.TestNegativeMinimrCliDriver.testNegativeCliDriver_mapreduce_stack_trace_hadoop20
          

          Test results: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/1090/testReport
          Console output: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/1090/console

          Messages:

          Executing org.apache.hive.ptest.execution.PrepPhase
          Executing org.apache.hive.ptest.execution.ExecutionPhase
          Executing org.apache.hive.ptest.execution.ReportingPhase
          Tests exited with: TestsFailedException: 1 tests failed
          

          This message is automatically generated.

          ATTACHMENT ID: 12625783

          Show
          Hive QA added a comment - Overall : -1 at least one tests failed Here are the results of testing the latest attachment: https://issues.apache.org/jira/secure/attachment/12625783/HIVE-6328.patch ERROR: -1 due to 1 failed/errored test(s), 4972 tests executed Failed tests: org.apache.hadoop.hive.cli.TestNegativeMinimrCliDriver.testNegativeCliDriver_mapreduce_stack_trace_hadoop20 Test results: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/1090/testReport Console output: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/1090/console Messages: Executing org.apache.hive.ptest.execution.PrepPhase Executing org.apache.hive.ptest.execution.ExecutionPhase Executing org.apache.hive.ptest.execution.ReportingPhase Tests exited with: TestsFailedException: 1 tests failed This message is automatically generated. ATTACHMENT ID: 12625783
          Hide
          Swarnim Kulkarni added a comment -

          +1(non-binding). Was able to do a quick verification to demonstrate the working.

          Show
          Swarnim Kulkarni added a comment - +1(non-binding). Was able to do a quick verification to demonstrate the working.
          Hide
          Vaibhav Gumashta added a comment -

          +1 (non-binding). Thanks a lot for the patch!

          Show
          Vaibhav Gumashta added a comment - +1 (non-binding). Thanks a lot for the patch!
          Xuefu Zhang made changes -
          Status Open [ 1 ] Patch Available [ 10002 ]
          Xuefu Zhang made changes -
          Field Original Value New Value
          Attachment HIVE-6328.patch [ 12625783 ]
          Xuefu Zhang created issue -

            People

            • Assignee:
              Xuefu Zhang
              Reporter:
              Xuefu Zhang
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development