Repository: bigtop
Updated Branches:
  refs/heads/master 6451d505b -> bf5b81032


BIGTOP-1915 Update Oozie to 4.2.0

Signed-off-by: Evans Ye <[email protected]>


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

Branch: refs/heads/master
Commit: bf5b81032c0a496d6795599b9f1b6d7d62f20baa
Parents: 6451d50
Author: Mike Grimes <[email protected]>
Authored: Tue Dec 1 11:57:37 2015 -0800
Committer: Evans Ye <[email protected]>
Committed: Thu Dec 3 04:22:20 2015 +0800

----------------------------------------------------------------------
 .../src/common/oozie/catalina.properties        |  2 +-
 .../src/common/oozie/do-component-build         | 17 +---
 .../src/common/oozie/install_oozie.sh           | 31 +++----
 bigtop-packages/src/common/oozie/oozie-env.sh   | 25 ++++--
 bigtop-packages/src/common/oozie/oozie-site.xml | 92 ++++++++++++++++++++
 .../src/common/oozie/patch0-OOZIE-2305.diff     | 42 +++++++++
 bigtop-packages/src/deb/oozie/rules             | 16 ++++
 bigtop-packages/src/rpm/oozie/SPECS/oozie.spec  | 26 +++++-
 bigtop.bom                                      |  2 +-
 9 files changed, 203 insertions(+), 50 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop-packages/src/common/oozie/catalina.properties
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/common/oozie/catalina.properties 
b/bigtop-packages/src/common/oozie/catalina.properties
index 21d7acb..9ed5fe0 100755
--- a/bigtop-packages/src/common/oozie/catalina.properties
+++ b/bigtop-packages/src/common/oozie/catalina.properties
@@ -44,7 +44,7 @@ 
package.definition=sun.,java.,org.apache.catalina.,org.apache.coyote.,org.apache
 #     "foo/*.jar": Add all the JARs of the specified folder as class 
 #                  repositories
 #     "foo/bar.jar": Add bar.jar as a class repository
-common.loader=/var/lib/oozie/*.jar,/usr/lib/hadoop/client/*.jar,/usr/lib/oozie/libserver/*.jar,${catalina.home}/lib,${catalina.home}/lib/*.jar
+common.loader=/var/lib/oozie/*.jar,/usr/lib/hadoop/client/*.jar,/usr/lib/oozie/lib/*.jar,${catalina.home}/lib,${catalina.home}/lib/*.jar
 
 #
 # List of comma-separated paths defining the contents of the "server" 

http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop-packages/src/common/oozie/do-component-build
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/common/oozie/do-component-build 
b/bigtop-packages/src/common/oozie/do-component-build
index 13b9505..47fefbf 100755
--- a/bigtop-packages/src/common/oozie/do-component-build
+++ b/bigtop-packages/src/common/oozie/do-component-build
@@ -76,20 +76,6 @@ if [ "${DO_MAVEN_DEPLOY}" = "deploy" ]; then
   EXTRA_GOALS="${EXTRA_GOALS} source:jar deploy"
 fi
 
-## Update hardcoded version of the Hadoop base to the current HADOOP VERSION
-## This approach might need to be reconsidered once OOZIE-1201 is fixed
-OLD_VERSION="2.3.0"
-echo "Replacing old target Hadoop version ${OLD_VERSION} with 
${HADOOP_VERSION}"
-POM_FILES="${WORKDIR}/hadooplibs/hadoop-2/pom.xml 
${WORKDIR}/hadooplibs/hadoop-distcp-2/pom.xml 
${WORKDIR}/hadooplibs/hadoop-test-2/pom.xml ${WORKDIR}/pom.xml"
-for pom in $POM_FILES; do
-  sed -i.orig -e "s#${OLD_VERSION}#${HADOOP_VERSION}#" $pom
-  grep ${HADOOP_VERSION} $pom 2>&1 > /dev/null
-  if [ $? != 0 ]; then
-    echo "Could not replace target hadoop version. Check if Oozie targets 
Hadoop $OLD_VERSION"
-    exit -1
-  fi
-done
-
 # Disable Codehaus repository since it's out of service
 sed -i.bak "/http:\/\/repository.codehaus.org/a\\
             <releases>\\
@@ -98,7 +84,7 @@ sed -i.bak "/http:\/\/repository.codehaus.org/a\\
 
 export MAVEN_OPTS="-Xmx512m -XX:MaxPermSize=128m"
 # Invoke Oozie build script
-${WORKDIR}/bin/mkdistro.sh -DjavaVersion=${JDK_VERSION} -DskipTests 
-Dhadoop.version=${HADOOP_VERSION} -Dhadoop.auth.version=${HADOOP_VERSION} 
${EXTRA_GOALS} -Dmaven.repo.local=${HOME}/.m2/repository "$@"
+${WORKDIR}/bin/mkdistro.sh -DjavaVersion=${JDK_VERSION} -DskipTests -Phadoop-2 
-Puber -Dhadoop.version=${HADOOP_VERSION} 
-Dhadoop.auth.version=${HADOOP_VERSION} -Dhive.version=${HIVE_VERSION} 
-Dpig.version=${PIG_VERSION} -Dsqoop.version=${SQOOP_VERSION} 
-Dspark.version=${SPARK_VERSION} ${EXTRA_GOALS} 
-Dmaven.repo.local=${HOME}/.m2/repository "$@"
 MKDISTRO_RESULT=$?
 if [ "${MKDISTRO_RESULT}" != "0" ]; then
   echo "ERROR: mkdistro.sh failed with error ${MKDISTRO_RESULT}"
@@ -127,7 +113,6 @@ if [ "${FULL_VERSION}" != "${OOZIE_VERSION}" ]; then
 fi
 
 cd ${EXPDIR}
-rm -rf ${EXPDIR}/oozie-client-*.tar.gz
 
 SRCDIR=${EXPDIR}/src
 mkdir -p ${SRCDIR}

http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop-packages/src/common/oozie/install_oozie.sh
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/common/oozie/install_oozie.sh 
b/bigtop-packages/src/common/oozie/install_oozie.sh
index aa7a146..7d81f8b 100755
--- a/bigtop-packages/src/common/oozie/install_oozie.sh
+++ b/bigtop-packages/src/common/oozie/install_oozie.sh
@@ -102,16 +102,10 @@ DOC_DIR=${DOC_DIR:-$CLIENT_PREFIX/usr/share/doc/oozie}
 BIN_DIR=${CLIENT_PREFIX}/usr/bin
 
 install -d -m 0755 ${CLIENT_LIB_DIR}
-install -d -m 0755 ${CLIENT_LIB_DIR}/bin
-cp -R ${BUILD_DIR}/bin/oozie ${CLIENT_LIB_DIR}/bin
-cp -R ${BUILD_DIR}/lib ${CLIENT_LIB_DIR}
+tar --strip-components=1 -zxf ${BUILD_DIR}/oozie-client-*.tar.gz -C 
${CLIENT_LIB_DIR}/
 install -d -m 0755 ${DOC_DIR}
-cp -R ${BUILD_DIR}/LICENSE.txt ${DOC_DIR}
-cp -R ${BUILD_DIR}/NOTICE.txt ${DOC_DIR}
+mv ${CLIENT_LIB_DIR}/*.txt ${DOC_DIR}/
 cp -R ${BUILD_DIR}/oozie-examples.tar.gz ${DOC_DIR}
-cp -R ${BUILD_DIR}/README.txt ${DOC_DIR}
-cp -R ${BUILD_DIR}/release-log.txt ${DOC_DIR}
-[ -f ${BUILD_DIR}/PATCH.txt ] && cp ${BUILD_DIR}/PATCH.txt ${DOC_DIR}
 cp -R ${BUILD_DIR}/docs/* ${DOC_DIR}
 rm -rf ${DOC_DIR}/target
 install -d -m 0755 ${MAN_DIR}
@@ -184,6 +178,7 @@ DATA_DIR=${SERVER_PREFIX}/var/lib/oozie
 
 install -d -m 0755 ${SERVER_LIB_DIR}
 install -d -m 0755 ${SERVER_LIB_DIR}/bin
+install -d -m 0755 ${SERVER_LIB_DIR}/lib
 install -d -m 0755 ${DATA_DIR}
 for file in ooziedb.sh oozied.sh oozie-sys.sh oozie-setup.sh ; do
   cp ${BUILD_DIR}/bin/$file ${SERVER_LIB_DIR}/bin
@@ -191,8 +186,10 @@ done
 
 install -d -m 0755 ${CONF_DIR}
 cp -r ${BUILD_DIR}/conf/* ${CONF_DIR}
-sed -i -e 
'/oozie.service.HadoopAccessorService.hadoop.configurations/,/<\/property>/s#<value>\*=hadoop-conf</value>#<value>*=/etc/hadoop/conf</value>#g'
 \
-          ${CONF_DIR}/oozie-site.xml
+# Remove Windows files
+rm -f ${CONF_DIR}/*.cmd
+
+cp ${EXTRA_DIR}/oozie-site.xml ${CONF_DIR}
 cp ${EXTRA_DIR}/oozie-env.sh ${CONF_DIR}
 install -d -m 0755 ${CONF_DIR}/action-conf
 cp ${EXTRA_DIR}/hive.xml ${CONF_DIR}/action-conf
@@ -210,7 +207,8 @@ cp -R ${BUILD_DIR}/oozie-server/webapps 
${SERVER_LIB_DIR}/webapps
 WEBAPP_DIR=${SERVER_LIB_DIR}/webapps/oozie
 mkdir ${WEBAPP_DIR}
 (cd ${WEBAPP_DIR} ; jar xf ${BUILD_DIR}/oozie.war)
-mv -f ${WEBAPP_DIR}/WEB-INF/lib ${SERVER_LIB_DIR}/libserver
+# OOZIE_HOME/lib
+mv -f ${WEBAPP_DIR}/WEB-INF/lib/* ${SERVER_LIB_DIR}/lib/
 touch ${SERVER_LIB_DIR}/webapps/oozie.war
 
 install -m 0755 ${EXTRA_DIR}/tomcat-deployment.sh 
${SERVER_LIB_DIR}/tomcat-deployment.sh
@@ -229,16 +227,7 @@ mv ${HTTPS_DIRECTORY}/conf/ssl/ssl-server.xml 
${HTTPS_DIRECTORY}/conf/server.xml
 mv ${HTTPS_DIRECTORY}/conf/ssl/ssl-web.xml ${HTTPS_DIRECTORY}/WEB-INF/web.xml
 rm -r ${HTTP_DIRECTORY}/conf/ssl
 
-# Create all the jars needed for tools execution
-install -d -m 0755 ${SERVER_LIB_DIR}/libtools
-for i in `cd ${BUILD_DIR}/libtools ; ls *` ; do
-  if [ -e ${SERVER_LIB_DIR}/libserver/$i ] ; then
-    ln -s ../libserver/$i ${SERVER_LIB_DIR}/libtools/$i
-  else
-    cp ${BUILD_DIR}/libtools/$i ${SERVER_LIB_DIR}/libtools/$i
-  fi
-done
-rm -rf ${SERVER_LIB_DIR}/libtools/hadoop-client-*.jar
+cp -R ${BUILD_DIR}/libtools ${SERVER_LIB_DIR}/
 
 # Provide a convenience symlink to be more consistent with tarball deployment
 ln -s ${DATA_DIR#${SERVER_PREFIX}} ${SERVER_LIB_DIR}/libext

http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop-packages/src/common/oozie/oozie-env.sh
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/common/oozie/oozie-env.sh 
b/bigtop-packages/src/common/oozie/oozie-env.sh
index c80f45d..825ab06 100755
--- a/bigtop-packages/src/common/oozie/oozie-env.sh
+++ b/bigtop-packages/src/common/oozie/oozie-env.sh
@@ -1,19 +1,21 @@
-#! /bin/bash
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
+#!/bin/bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
 #
-#     http://www.apache.org/licenses/LICENSE-2.0
+#      http://www.apache.org/licenses/LICENSE-2.0
 #
 # Unless required by applicable law or agreed to in writing, software
 # distributed under the License is distributed on an "AS IS" BASIS,
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+#
 
 export OOZIE_DATA=/var/lib/oozie
 export OOZIE_CATALINA_HOME=/usr/lib/bigtop-tomcat
@@ -35,6 +37,7 @@ export OOZIE_CONFIG=/etc/oozie/conf
 
 # Oozie logs directory
 #
+# export OOZIE_LOG=${OOZIE_HOME}/logs
 export OOZIE_LOG=/var/log/oozie
 
 # Oozie Log4J configuration file to load from Oozie configuration directory
@@ -68,3 +71,7 @@ export OOZIE_LOG=/var/log/oozie
 # The password of the keystore for the Oozie server if using SSL (HTTPS)
 #
 # export OOZIE_HTTPS_KEYSTORE_PASS=password
+
+# The Oozie Instance ID
+#
+# export OOZIE_INSTANCE_ID="${OOZIE_HTTP_HOSTNAME}"

http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop-packages/src/common/oozie/oozie-site.xml
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/common/oozie/oozie-site.xml 
b/bigtop-packages/src/common/oozie/oozie-site.xml
new file mode 100644
index 0000000..8d391ad
--- /dev/null
+++ b/bigtop-packages/src/common/oozie/oozie-site.xml
@@ -0,0 +1,92 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<configuration>
+
+    <!--
+        Refer to the oozie-default.xml file for the complete list of
+        Oozie configuration properties and their default values.
+    -->
+
+    <!-- Proxyuser Configuration -->
+
+    <!--
+
+    <property>
+        <name>oozie.service.ProxyUserService.proxyuser.#USER#.hosts</name>
+        <value>*</value>
+        <description>
+            List of hosts the '#USER#' user is allowed to perform 'doAs'
+            operations.
+
+            The '#USER#' must be replaced with the username o the user who is
+            allowed to perform 'doAs' operations.
+
+            The value can be the '*' wildcard or a list of hostnames.
+
+            For multiple users copy this property and replace the user name
+            in the property name.
+        </description>
+    </property>
+
+    <property>
+        <name>oozie.service.ProxyUserService.proxyuser.#USER#.groups</name>
+        <value>*</value>
+        <description>
+            List of groups the '#USER#' user is allowed to impersonate users
+            from to perform 'doAs' operations.
+
+            The '#USER#' must be replaced with the username o the user who is
+            allowed to perform 'doAs' operations.
+
+            The value can be the '*' wildcard or a list of groups.
+
+            For multiple users copy this property and replace the user name
+            in the property name.
+        </description>
+    </property>
+
+    -->
+
+    <property>
+        <name>oozie.service.HadoopAccessorService.hadoop.configurations</name>
+        <value>*=/etc/hadoop/conf</value>
+        <description>
+            Comma separated AUTHORITY=HADOOP_CONF_DIR, where AUTHORITY is the 
HOST:PORT of
+            the Hadoop service (JobTracker, YARN, HDFS). The wildcard '*' 
configuration is
+            used when there is no exact match for an authority. The 
HADOOP_CONF_DIR contains
+            the relevant Hadoop *-site.xml files. If the path is relative is 
looked within
+            the Oozie configuration directory; though the path can be absolute 
(i.e. to point
+            to Hadoop client conf/ directories in the local filesystem.
+        </description>
+    </property>
+
+    <property>
+        
<name>oozie.service.SparkConfigurationService.spark.configurations</name>
+        <value>*=/etc/spark/conf</value>
+        <description>
+            Comma separated AUTHORITY=SPARK_CONF_DIR, where AUTHORITY is the 
HOST:PORT of
+            the ResourceManager of a YARN cluster. The wildcard '*' 
configuration is used when
+            there is no exact match for an authority. The SPARK_CONF_DIR 
contains the relevant
+            spark-defaults.conf properties file. If the path is relative is 
looked within the
+            Oozie configuration directory; though the path can be absolute.
+            This is only used when the Spark master is set to either 
"yarn-client" or "yarn-cluster".
+        </description>
+    </property>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop-packages/src/common/oozie/patch0-OOZIE-2305.diff
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/common/oozie/patch0-OOZIE-2305.diff 
b/bigtop-packages/src/common/oozie/patch0-OOZIE-2305.diff
new file mode 100644
index 0000000..ee8463b
--- /dev/null
+++ b/bigtop-packages/src/common/oozie/patch0-OOZIE-2305.diff
@@ -0,0 +1,42 @@
+--- 
oozie-4.2.0/core/src/main/java/org/apache/oozie/dependency/HCatURIHandler.java
++++ 
oozie-4.2.0/core/src/main/java/org/apache/oozie/dependency/HCatURIHandler.java
+@@ -48,6 +48,9 @@ import org.apache.oozie.service.Services;
+ import org.apache.oozie.service.URIHandlerService;
+ import org.apache.oozie.util.HCatURI;
+ import org.apache.oozie.util.XLog;
++import org.apache.hadoop.hive.thrift.DelegationTokenIdentifier;
++import org.apache.hadoop.io.Text;
++import org.apache.hadoop.security.token.Token;
+
+ public class HCatURIHandler implements URIHandler {
+
+@@ -270,8 +273,10 @@ public class HCatURIHandler implements URIHandler {
+                     delegationToken = tokenClient.getDelegationToken(user, 
UserGroupInformation.getLoginUser()
+                             .getUserName());
+                     // Store Delegation token in the UGI
+-                    ShimLoader.getHadoopShims().setTokenStr(ugi, 
delegationToken,
+-                            hiveConf.get("hive.metastore.token.signature"));
++                    Token<DelegationTokenIdentifier> token = new 
Token<DelegationTokenIdentifier>();
++                    token.decodeFromUrlString(delegationToken);
++                    token.setService(new 
Text(hiveConf.get("hive.metastore.token.signature")));
++                    ugi.addToken(token);
+                 }
+                 finally {
+                     if (tokenClient != null)
+--- oozie-4.2.0/core/src/test/java/org/apache/oozie/test/hive/MiniHS2.java
++++ oozie-4.2.0/core/src/test/java/org/apache/oozie/test/hive/MiniHS2.java
+@@ -84,7 +84,6 @@ public class MiniHS2 extends AbstractHiveService {
+     hiveConf.setVar(ConfVars.HIVE_SERVER2_THRIFT_BIND_HOST, getHost());
+     hiveConf.setIntVar(ConfVars.HIVE_SERVER2_THRIFT_PORT, getBinaryPort());
+     hiveConf.setIntVar(ConfVars.HIVE_SERVER2_THRIFT_HTTP_PORT, getHttpPort());
+-    HiveMetaStore.HMSHandler.resetDefaultDBFlag();
+
+     Path scratchDir = new Path(baseDfsDir, "scratch");
+     fs.mkdirs(scratchDir);
+@@ -209,4 +208,4 @@ public class MiniHS2 extends AbstractHiveService {
+     } while (true);
+   }
+
+-}
+\ No newline at end of file
++}

http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop-packages/src/deb/oozie/rules
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/deb/oozie/rules 
b/bigtop-packages/src/deb/oozie/rules
index 531aeb2..0df5cab 100755
--- a/bigtop-packages/src/deb/oozie/rules
+++ b/bigtop-packages/src/deb/oozie/rules
@@ -40,3 +40,19 @@ override_dh_auto_install:
        ln -s -f /var/lib/oozie/ext-2.2 
debian/oozie/usr/lib/oozie/webapps/oozie/ext-2.2
        rm -rf                        
debian/oozie/usr/lib/oozie/webapps/oozie/docs
        ln -s -f /usr/share/doc/oozie 
debian/oozie/usr/lib/oozie/webapps/oozie/docs
+
+       # Oozie server
+       rm -rf  debian/oozie/usr/lib/oozie/lib/hadoop-*.jar
+       ln -sf /usr/lib/hadoop/client/hadoop-annotations.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-auth.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-common.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-hdfs.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-mapreduce-client-app.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-mapreduce-client-common.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-mapreduce-client-core.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-mapreduce-client-jobclient.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-mapreduce-client-shuffle.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-yarn-api.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-yarn-client.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-yarn-common.jar 
debian/oozie/usr/lib/oozie/lib/
+       ln -sf /usr/lib/hadoop/client/hadoop-yarn-server-common.jar 
debian/oozie/usr/lib/oozie/lib/
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec 
b/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec
index 1355655..81099fd 100644
--- a/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec
+++ b/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec
@@ -19,6 +19,7 @@
 %define conf_oozie_dist %{conf_oozie}.dist
 %define tomcat_conf_oozie %{_sysconfdir}/%{name}/tomcat-conf
 %define data_oozie /var/lib/oozie
+%define lib_hadoop /usr/lib/hadoop
 
 %if  %{!?suse_version:1}0
   %define doc_oozie %{_docdir}/oozie-%{oozie_version}
@@ -64,6 +65,9 @@ Source6: catalina.properties
 Source7: context.xml
 Source8: hive.xml
 Source9: tomcat-deployment.sh
+Source10: oozie-site.xml
+Source11: bigtop.bom
+#BIGTOP_PATCH_FILES
 Requires(pre): /usr/sbin/groupadd, /usr/sbin/useradd
 Requires(post): /sbin/chkconfig
 Requires(preun): /sbin/chkconfig, /sbin/service
@@ -133,6 +137,8 @@ Requires: bigtop-utils >= 0.7
 %prep
 %setup -n oozie-%{oozie_base_version}
 
+#BIGTOP_PATCH_COMMANDS
+
 %build
     mkdir -p distro/downloads
     env DO_MAVEN_DEPLOY="" FULL_VERSION=%{oozie_base_version} bash -x 
%{SOURCE1}
@@ -145,6 +151,22 @@ Requires: bigtop-utils >= 0.7
 %__rm  -rf              $RPM_BUILD_ROOT/%{lib_oozie}/webapps/oozie/docs
 %__ln_s -f %{doc_oozie} $RPM_BUILD_ROOT/%{lib_oozie}/webapps/oozie/docs
 
+# Oozie server
+%__rm  -rf $RPM_BUILD_ROOT/%{lib_oozie}/lib/hadoop-*.jar
+%__ln_s -f %{lib_hadoop}/client/hadoop-annotations.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-auth.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-common.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-hdfs.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-mapreduce-client-app.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-mapreduce-client-common.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-mapreduce-client-core.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-mapreduce-client-jobclient.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-mapreduce-client-shuffle.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-yarn-api.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-yarn-client.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-yarn-common.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+%__ln_s -f %{lib_hadoop}/client/hadoop-yarn-server-common.jar 
$RPM_BUILD_ROOT/%{lib_oozie}/lib/
+
 %__install -d -m 0755 $RPM_BUILD_ROOT/usr/bin
 
 %__install -d  -m 0755  %{buildroot}/%{_localstatedir}/log/oozie
@@ -188,7 +210,7 @@ fi
 %{lib_oozie}/bin/oozie-setup.sh
 %{lib_oozie}/webapps
 %{lib_oozie}/libtools
-%{lib_oozie}/libserver
+%{lib_oozie}/lib
 %{lib_oozie}/oozie-sharelib.tar.gz
 %{lib_oozie}/libext
 %{lib_oozie}/tomcat-deployment.sh
@@ -202,7 +224,7 @@ fi
 %files client
 %defattr(-,root,root)
 %{usr_bin}/oozie
-%dir %{lib_oozie}/bin
+%dir %{lib_oozie}
 %{lib_oozie}/bin/oozie
 %{lib_oozie}/lib
 %doc %{doc_oozie}

http://git-wip-us.apache.org/repos/asf/bigtop/blob/bf5b8103/bigtop.bom
----------------------------------------------------------------------
diff --git a/bigtop.bom b/bigtop.bom
index dacfb4e..01e399f 100644
--- a/bigtop.bom
+++ b/bigtop.bom
@@ -203,7 +203,7 @@ bigtop {
     'oozie' {
       name    = 'oozie'
       relNotes = 'Apache Oozie'
-      version { base = '4.0.1'; pkg = base; release = 1 }
+      version { base = '4.2.0'; pkg = base; release = 1 }
       tarball { destination = "$name-${version.base}.tar.gz"
                 source      = destination }
       url     { download_path = "/$name/${version.base}/"

Reply via email to