hive git commit: HIVE-19728: beeline with USE_BEELINE_FOR_HIVE_CLI fails when trying to set hive.aux.jars.path (Daniel Voros reviewed by Vaibhav Gumashta)

2018-06-01 Thread vgumashta
Repository: hive
Updated Branches:
  refs/heads/master 17d661e5d -> 48d1a6a5e


HIVE-19728: beeline with USE_BEELINE_FOR_HIVE_CLI fails when trying to set 
hive.aux.jars.path (Daniel Voros reviewed by Vaibhav Gumashta)


Project: http://git-wip-us.apache.org/repos/asf/hive/repo
Commit: http://git-wip-us.apache.org/repos/asf/hive/commit/48d1a6a5
Tree: http://git-wip-us.apache.org/repos/asf/hive/tree/48d1a6a5
Diff: http://git-wip-us.apache.org/repos/asf/hive/diff/48d1a6a5

Branch: refs/heads/master
Commit: 48d1a6a5e47085cdc3a3d71649ddd28af7566c88
Parents: 17d661e
Author: Vaibhav Gumashta 
Authored: Fri Jun 1 10:49:48 2018 -0700
Committer: Vaibhav Gumashta 
Committed: Fri Jun 1 10:50:36 2018 -0700

--
 bin/ext/cli.sh | 22 +++---
 bin/hive   |  4 
 2 files changed, 7 insertions(+), 19 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/hive/blob/48d1a6a5/bin/ext/cli.sh
--
diff --git a/bin/ext/cli.sh b/bin/ext/cli.sh
index 14337c1..c837508 100644
--- a/bin/ext/cli.sh
+++ b/bin/ext/cli.sh
@@ -24,25 +24,9 @@ fi
 
 updateCli() {
   if [ "$USE_DEPRECATED_CLI" == "true" ]; then
-if [ "$USE_BEELINE_FOR_HIVE_CLI" == "true" ]; then
- CLASS=org.apache.hive.beeline.BeeLine;
-  # include only the beeline client jar and its dependencies
-  beelineJarPath=`ls ${HIVE_LIB}/hive-beeline-*.jar`
-  superCsvJarPath=`ls ${HIVE_LIB}/super-csv-*.jar`
-  jlineJarPath=`ls ${HIVE_LIB}/jline-*.jar`
-  hadoopClasspath=""
-  if [[ -n "${HADOOP_CLASSPATH}" ]]
-  then
-hadoopClasspath="${HADOOP_CLASSPATH}:"
-  fi
-  export 
HADOOP_CLASSPATH="${hadoopClasspath}${HIVE_CONF_DIR}:${beelineJarPath}:${superCsvJarPath}:${jlineJarPath}"
-  export HADOOP_CLIENT_OPTS="$HADOOP_CLIENT_OPTS 
-Dlog4j.configurationFile=beeline-log4j2.properties "
-  exec $HADOOP jar ${beelineJarPath} $CLASS $HIVE_OPTS "$@"
-else
-  export HADOOP_CLIENT_OPTS=" -Dproc_hivecli $HADOOP_CLIENT_OPTS "
-  CLASS=org.apache.hadoop.hive.cli.CliDriver
-  JAR=hive-cli-*.jar
-fi
+export HADOOP_CLIENT_OPTS=" -Dproc_hivecli $HADOOP_CLIENT_OPTS "
+CLASS=org.apache.hadoop.hive.cli.CliDriver
+JAR=hive-cli-*.jar
   else
 export HADOOP_CLIENT_OPTS=" -Dproc_beeline $HADOOP_CLIENT_OPTS 
-Dlog4j.configurationFile=beeline-log4j2.properties"
 CLASS=org.apache.hive.beeline.cli.HiveCli

http://git-wip-us.apache.org/repos/asf/hive/blob/48d1a6a5/bin/hive
--
diff --git a/bin/hive b/bin/hive
index 87be599..c54c6fb 100755
--- a/bin/hive
+++ b/bin/hive
@@ -85,6 +85,10 @@ if [ "$SERVICE" = "" ] ; then
   fi
 fi
 
+if [[ "$SERVICE" == "cli" && "$USE_BEELINE_FOR_HIVE_CLI" == "true" ]] ; then
+  SERVICE="beeline"
+fi
+
 if [[ "$SERVICE" =~ 
^(help|version|orcfiledump|rcfilecat|schemaTool|cleardanglingscratchdir|metastore|beeline|llapstatus|llap)$
 ]] ; then
   SKIP_HBASECP=true
 fi



hive git commit: HIVE-19728: beeline with USE_BEELINE_FOR_HIVE_CLI fails when trying to set hive.aux.jars.path (Daniel Voros reviewed by Vaibhav Gumashta)

2018-06-01 Thread vgumashta
Repository: hive
Updated Branches:
  refs/heads/branch-3 8350e61a0 -> 6f5d4dd87


HIVE-19728: beeline with USE_BEELINE_FOR_HIVE_CLI fails when trying to set 
hive.aux.jars.path (Daniel Voros reviewed by Vaibhav Gumashta)


Project: http://git-wip-us.apache.org/repos/asf/hive/repo
Commit: http://git-wip-us.apache.org/repos/asf/hive/commit/6f5d4dd8
Tree: http://git-wip-us.apache.org/repos/asf/hive/tree/6f5d4dd8
Diff: http://git-wip-us.apache.org/repos/asf/hive/diff/6f5d4dd8

Branch: refs/heads/branch-3
Commit: 6f5d4dd87df7dc63d81a2c57a013f4f94fa60099
Parents: 8350e61
Author: Vaibhav Gumashta 
Authored: Fri Jun 1 10:49:48 2018 -0700
Committer: Vaibhav Gumashta 
Committed: Fri Jun 1 10:49:48 2018 -0700

--
 bin/ext/cli.sh | 22 +++---
 bin/hive   |  4 
 2 files changed, 7 insertions(+), 19 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/hive/blob/6f5d4dd8/bin/ext/cli.sh
--
diff --git a/bin/ext/cli.sh b/bin/ext/cli.sh
index 14337c1..c837508 100644
--- a/bin/ext/cli.sh
+++ b/bin/ext/cli.sh
@@ -24,25 +24,9 @@ fi
 
 updateCli() {
   if [ "$USE_DEPRECATED_CLI" == "true" ]; then
-if [ "$USE_BEELINE_FOR_HIVE_CLI" == "true" ]; then
- CLASS=org.apache.hive.beeline.BeeLine;
-  # include only the beeline client jar and its dependencies
-  beelineJarPath=`ls ${HIVE_LIB}/hive-beeline-*.jar`
-  superCsvJarPath=`ls ${HIVE_LIB}/super-csv-*.jar`
-  jlineJarPath=`ls ${HIVE_LIB}/jline-*.jar`
-  hadoopClasspath=""
-  if [[ -n "${HADOOP_CLASSPATH}" ]]
-  then
-hadoopClasspath="${HADOOP_CLASSPATH}:"
-  fi
-  export 
HADOOP_CLASSPATH="${hadoopClasspath}${HIVE_CONF_DIR}:${beelineJarPath}:${superCsvJarPath}:${jlineJarPath}"
-  export HADOOP_CLIENT_OPTS="$HADOOP_CLIENT_OPTS 
-Dlog4j.configurationFile=beeline-log4j2.properties "
-  exec $HADOOP jar ${beelineJarPath} $CLASS $HIVE_OPTS "$@"
-else
-  export HADOOP_CLIENT_OPTS=" -Dproc_hivecli $HADOOP_CLIENT_OPTS "
-  CLASS=org.apache.hadoop.hive.cli.CliDriver
-  JAR=hive-cli-*.jar
-fi
+export HADOOP_CLIENT_OPTS=" -Dproc_hivecli $HADOOP_CLIENT_OPTS "
+CLASS=org.apache.hadoop.hive.cli.CliDriver
+JAR=hive-cli-*.jar
   else
 export HADOOP_CLIENT_OPTS=" -Dproc_beeline $HADOOP_CLIENT_OPTS 
-Dlog4j.configurationFile=beeline-log4j2.properties"
 CLASS=org.apache.hive.beeline.cli.HiveCli

http://git-wip-us.apache.org/repos/asf/hive/blob/6f5d4dd8/bin/hive
--
diff --git a/bin/hive b/bin/hive
index 87be599..c54c6fb 100755
--- a/bin/hive
+++ b/bin/hive
@@ -85,6 +85,10 @@ if [ "$SERVICE" = "" ] ; then
   fi
 fi
 
+if [[ "$SERVICE" == "cli" && "$USE_BEELINE_FOR_HIVE_CLI" == "true" ]] ; then
+  SERVICE="beeline"
+fi
+
 if [[ "$SERVICE" =~ 
^(help|version|orcfiledump|rcfilecat|schemaTool|cleardanglingscratchdir|metastore|beeline|llapstatus|llap)$
 ]] ; then
   SKIP_HBASECP=true
 fi