hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gop...@apache.org
Subject hive git commit: HIVE-13110: LLAP: Package log4j2 jars into Slider pkg (Gopal V, reviewed by Gunther Hagleitner)
Date Tue, 23 Feb 2016 23:44:22 GMT
Repository: hive
Updated Branches:
  refs/heads/master 1c2d7ba35 -> b123c5a30


HIVE-13110: LLAP: Package log4j2 jars into Slider pkg (Gopal V, reviewed by Gunther Hagleitner)


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

Branch: refs/heads/master
Commit: b123c5a303cb8d0c3ca1699c906b5a51a6517662
Parents: 1c2d7ba
Author: Gopal V <gopalv@apache.org>
Authored: Tue Feb 23 15:39:49 2016 -0800
Committer: Gopal V <gopalv@apache.org>
Committed: Tue Feb 23 15:39:49 2016 -0800

----------------------------------------------------------------------
 llap-server/bin/runLlapDaemon.sh                |  2 +-
 .../hadoop/hive/llap/cli/LlapServiceDriver.java | 36 +++++++++++++-------
 2 files changed, 25 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hive/blob/b123c5a3/llap-server/bin/runLlapDaemon.sh
----------------------------------------------------------------------
diff --git a/llap-server/bin/runLlapDaemon.sh b/llap-server/bin/runLlapDaemon.sh
index f652ada..445a41e 100755
--- a/llap-server/bin/runLlapDaemon.sh
+++ b/llap-server/bin/runLlapDaemon.sh
@@ -82,7 +82,7 @@ if [ ! -n "${LLAP_DAEMON_LOG_LEVEL}" ]; then
   LLAP_DAEMON_LOG_LEVEL=${LOG_LEVEL_DEFAULT}
 fi
 
-CLASSPATH=${LLAP_DAEMON_CONF_DIR}:${LLAP_DAEMON_HOME}/lib/*:`${HADOOP_PREFIX}/bin/hadoop
classpath`:.
+CLASSPATH=${LLAP_DAEMON_CONF_DIR}:${LLAP_DAEMON_HOME}/lib/*:${LLAP_DAEMON_HOME}/lib/tez/*:`${HADOOP_PREFIX}/bin/hadoop
classpath`:.
 
 if [ -n "LLAP_DAEMON_USER_CLASSPATH" ]; then
   CLASSPATH=${CLASSPATH}:${LLAP_DAEMON_USER_CLASSPATH}

http://git-wip-us.apache.org/repos/asf/hive/blob/b123c5a3/llap-server/src/java/org/apache/hadoop/hive/llap/cli/LlapServiceDriver.java
----------------------------------------------------------------------
diff --git a/llap-server/src/java/org/apache/hadoop/hive/llap/cli/LlapServiceDriver.java b/llap-server/src/java/org/apache/hadoop/hive/llap/cli/LlapServiceDriver.java
index 8404974..8fdec2f 100644
--- a/llap-server/src/java/org/apache/hadoop/hive/llap/cli/LlapServiceDriver.java
+++ b/llap-server/src/java/org/apache/hadoop/hive/llap/cli/LlapServiceDriver.java
@@ -243,6 +243,7 @@ public class LlapServiceDriver {
 
 
     Path libDir = new Path(tmpDir, "lib");
+    Path tezDir = new Path(libDir, "tez");
 
     String tezLibs = conf.get(TezConfiguration.TEZ_LIB_URIS);
     if (tezLibs == null) {
@@ -251,21 +252,32 @@ public class LlapServiceDriver {
     if (LOG.isDebugEnabled()) {
       LOG.debug("Copying tez libs from " + tezLibs);
     }
-    lfs.mkdirs(libDir);
+    lfs.mkdirs(tezDir);
     fs.copyToLocalFile(new Path(tezLibs), new Path(libDir, "tez.tar.gz"));
-    CompressionUtils.unTar(new Path(libDir, "tez.tar.gz").toString(), libDir.toString(),
true);
+    CompressionUtils.unTar(new Path(libDir, "tez.tar.gz").toString(), tezDir.toString(),
true);
     lfs.delete(new Path(libDir, "tez.tar.gz"), false);
 
-    // llap-common
-    lfs.copyFromLocalFile(new Path(Utilities.jarFinderGetJar(LlapDaemonProtocolProtos.class)),
libDir);
-    // llap-tez
-    lfs.copyFromLocalFile(new Path(Utilities.jarFinderGetJar(LlapTezUtils.class)), libDir);
-    // llap-server
-    lfs.copyFromLocalFile(new Path(Utilities.jarFinderGetJar(LlapInputFormat.class)), libDir);
-    // hive-exec
-    lfs.copyFromLocalFile(new Path(Utilities.jarFinderGetJar(HiveInputFormat.class)), libDir);
-    // hive-common (https deps)
-    lfs.copyFromLocalFile(new Path(Utilities.jarFinderGetJar(SslSocketConnector.class)),
libDir);
+    Class<?>[] dependencies = new Class<?>[] {
+        LlapDaemonProtocolProtos.class, // llap-common
+        LlapTezUtils.class, // llap-tez
+        LlapInputFormat.class, // llap-server
+        HiveInputFormat.class, // hive-exec
+        SslSocketConnector.class, // hive-common (https deps)
+        // log4j2
+        com.lmax.disruptor.RingBuffer.class, // disruptor
+        org.apache.logging.log4j.Logger.class, // log4j-api
+        org.apache.logging.log4j.core.Appender.class, // log4j-core
+        org.apache.logging.slf4j.Log4jLogger.class, // log4j-slf4j
+    };
+
+    for (Class<?> c : dependencies) {
+      Path jarPath = new Path(Utilities.jarFinderGetJar(c));
+      lfs.copyFromLocalFile(jarPath, libDir);
+      if (LOG.isDebugEnabled()) {
+        LOG.debug("Copying " + jarPath + " to " + libDir);
+      }
+    }
+
 
     // copy default aux classes (json/hbase)
 


Mime
View raw message