From a0ee9adfd36b4ec60bffb9986f8cff1efe7ac830 Mon Sep 17 00:00:00 2001 From: Alejandro Abdelnur Date: Wed, 14 Mar 2012 17:01:34 +0000 Subject: [PATCH] HDFS-3057. httpfs and hdfs launcher scripts should honor CATALINA_HOME and HADOOP_LIBEXEC_DIR (rvs via tucu) git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1300637 13f79535-47bb-0310-9956-ffa450edef68 --- .../hadoop-hdfs-httpfs/src/main/libexec/httpfs-config.sh | 7 +++++++ .../hadoop-hdfs-httpfs/src/main/sbin/httpfs.sh | 6 +++--- hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt | 3 +++ 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/libexec/httpfs-config.sh b/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/libexec/httpfs-config.sh index a72d62927c..02e1a7172c 100644 --- a/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/libexec/httpfs-config.sh +++ b/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/libexec/httpfs-config.sh @@ -150,6 +150,13 @@ else print "Using CATALINA_BASE: ${CATALINA_BASE}" fi +if [ "${HTTPFS_CATALINA_HOME}" = "" ]; then + export HTTPFS_CATALINA_HOME=${CATALINA_BASE} + print "Setting HTTPFS_CATALINA_HOME: ${HTTPFS_CATALINA_HOME}" +else + print "Using HTTPFS_CATALINA_HOME: ${HTTPFS_CATALINA_HOME}" +fi + if [ "${CATALINA_OUT}" = "" ]; then export CATALINA_OUT=${HTTPFS_LOG}/httpfs-catalina.out print "Setting CATALINA_OUT: ${CATALINA_OUT}" diff --git a/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/sbin/httpfs.sh b/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/sbin/httpfs.sh index e45bd42d00..cefe11400d 100644 --- a/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/sbin/httpfs.sh +++ b/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/sbin/httpfs.sh @@ -29,7 +29,7 @@ done BASEDIR=`dirname ${PRG}` BASEDIR=`cd ${BASEDIR}/..;pwd` -source ${BASEDIR}/libexec/httpfs-config.sh +source ${HADOOP_LIBEXEC_DIR:-${BASEDIR}/libexec}/httpfs-config.sh # The Java System property 'httpfs.http.port' it is not used by HttpFS, # it is used in Tomcat's server.xml configuration file @@ -55,8 +55,8 @@ if [ "${1}" = "stop" ]; then fi if [ "${HTTPFS_SILENT}" != "true" ]; then - ${CATALINA_BASE:-"${BASEDIR}/share/hadoop/httpfs/tomcat"}/bin/catalina.sh "$@" + ${HTTPFS_CATALINA_HOME}/bin/catalina.sh "$@" else - ${CATALINA_BASE:-"${BASEDIR}/share/hadoop/httpfs/tomcat"}/bin/catalina.sh "$@" > /dev/null + ${HTTPFS_CATALINA_HOME}/bin/catalina.sh "$@" > /dev/null fi diff --git a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt index 890f91a029..3d4b57fb4f 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt +++ b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt @@ -228,6 +228,9 @@ Release 0.23.3 - UNRELEASED HDFS-3082. Clean up FSDatasetInterface and change DataNode.data to package private. (szetszwo) + HDFS-3057. httpfs and hdfs launcher scripts should honor CATALINA_HOME + and HADOOP_LIBEXEC_DIR (rvs via tucu) + OPTIMIZATIONS HDFS-3024. Improve performance of stringification in addStoredBlock (todd)