From hcatalog-commits-return-1151-apmail-incubator-hcatalog-commits-archive=incubator.apache.org@incubator.apache.org Wed Jan 2 18:11:17 2013 Return-Path: X-Original-To: apmail-incubator-hcatalog-commits-archive@minotaur.apache.org Delivered-To: apmail-incubator-hcatalog-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id F3EA8E550 for ; Wed, 2 Jan 2013 18:11:16 +0000 (UTC) Received: (qmail 22069 invoked by uid 500); 2 Jan 2013 18:11:16 -0000 Delivered-To: apmail-incubator-hcatalog-commits-archive@incubator.apache.org Received: (qmail 22040 invoked by uid 500); 2 Jan 2013 18:11:16 -0000 Mailing-List: contact hcatalog-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hcatalog-dev@incubator.apache.org Delivered-To: mailing list hcatalog-commits@incubator.apache.org Received: (qmail 22033 invoked by uid 99); 2 Jan 2013 18:11:16 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Jan 2013 18:11:16 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Jan 2013 18:11:09 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id F20B22388980; Wed, 2 Jan 2013 18:10:49 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1427888 - in /incubator/hcatalog/branches/branch-0.5: ./ build-support/ant/ build-support/checkstyle/ conf/ webhcat/svr/ webhcat/svr/src/main/bin/ webhcat/svr/src/main/config/ webhcat/svr/src/main/java/org/apache/hcatalog/templeton/ Date: Wed, 02 Jan 2013 18:10:49 -0000 To: hcatalog-commits@incubator.apache.org From: gates@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20130102181049.F20B22388980@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: gates Date: Wed Jan 2 18:10:48 2013 New Revision: 1427888 URL: http://svn.apache.org/viewvc?rev=1427888&view=rev Log: HCATALOG-549 rename webhcat config and shell scripts to use webhcat in the names Added: incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_config.sh incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_server.sh incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/ incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-default.xml incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-log4j.properties Removed: incubator/hcatalog/branches/branch-0.5/conf/templeton-default.xml incubator/hcatalog/branches/branch-0.5/conf/templeton-log4j.properties incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/templeton_config.sh incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/templeton_server.sh Modified: incubator/hcatalog/branches/branch-0.5/CHANGES.txt incubator/hcatalog/branches/branch-0.5/build-support/ant/build-common.xml incubator/hcatalog/branches/branch-0.5/build-support/ant/deploy.xml incubator/hcatalog/branches/branch-0.5/build-support/checkstyle/apache_header.txt incubator/hcatalog/branches/branch-0.5/build.xml incubator/hcatalog/branches/branch-0.5/pom.xml incubator/hcatalog/branches/branch-0.5/webhcat/svr/build.xml incubator/hcatalog/branches/branch-0.5/webhcat/svr/pom.xml incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/java/org/apache/hcatalog/templeton/AppConfig.java Modified: incubator/hcatalog/branches/branch-0.5/CHANGES.txt URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/CHANGES.txt?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/CHANGES.txt (original) +++ incubator/hcatalog/branches/branch-0.5/CHANGES.txt Wed Jan 2 18:10:48 2013 @@ -43,6 +43,8 @@ Release 0.5.0 - Unreleased HCAT-427 Document storage-based authorization (lefty via gates) IMPROVEMENTS + HCAT-549 rename webhcat config and shell scripts to use webhcat in the names (thejas via gates) + HCAT-446 Enforce apache headers for all HCatalog code (traviscrawford via gates) HCAT-564 test.sh should let users specify the ant version (traviscrawford) Modified: incubator/hcatalog/branches/branch-0.5/build-support/ant/build-common.xml URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/build-support/ant/build-common.xml?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/build-support/ant/build-common.xml (original) +++ incubator/hcatalog/branches/branch-0.5/build-support/ant/build-common.xml Wed Jan 2 18:10:48 2013 @@ -61,6 +61,17 @@ + + + + + + + <_javac srcDir="${basedir}/src/main/java" @@ -80,7 +91,7 @@ <_junit srcDir="${basedir}/src/test/java"/> - + Modified: incubator/hcatalog/branches/branch-0.5/build-support/ant/deploy.xml URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/build-support/ant/deploy.xml?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/build-support/ant/deploy.xml (original) +++ incubator/hcatalog/branches/branch-0.5/build-support/ant/deploy.xml Wed Jan 2 18:10:48 2013 @@ -72,6 +72,15 @@ + + + + + + + + Modified: incubator/hcatalog/branches/branch-0.5/build-support/checkstyle/apache_header.txt URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/build-support/checkstyle/apache_header.txt?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/build-support/checkstyle/apache_header.txt (original) +++ incubator/hcatalog/branches/branch-0.5/build-support/checkstyle/apache_header.txt Wed Jan 2 18:10:48 2013 @@ -16,4 +16,4 @@ ^\W*"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY$ ^\W*KIND, either express or implied. See the License for the$ ^\W*specific language governing permissions and limitations$ -^\W*under the License.$ \ No newline at end of file +^\W*under the License.$ Modified: incubator/hcatalog/branches/branch-0.5/build.xml URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/build.xml?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/build.xml (original) +++ incubator/hcatalog/branches/branch-0.5/build.xml Wed Jan 2 18:10:48 2013 @@ -95,7 +95,6 @@ - @@ -198,9 +197,13 @@ + + + + @@ -292,9 +295,18 @@ + + + + + + + + + @@ -322,6 +334,10 @@ + + + + Modified: incubator/hcatalog/branches/branch-0.5/pom.xml URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/pom.xml?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/pom.xml (original) +++ incubator/hcatalog/branches/branch-0.5/pom.xml Wed Jan 2 18:10:48 2013 @@ -31,12 +31,13 @@ 0.92.0 ${project.version} 0.10.0-SNAPSHOT - 1.8.8 - 1.14 + 1.8.3 + 1.9.1 7.6.0.v20120127 1.1 0.8.0 1.6.1 + 1.4 3.4.3 Modified: incubator/hcatalog/branches/branch-0.5/webhcat/svr/build.xml URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/webhcat/svr/build.xml?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/webhcat/svr/build.xml (original) +++ incubator/hcatalog/branches/branch-0.5/webhcat/svr/build.xml Wed Jan 2 18:10:48 2013 @@ -26,10 +26,12 @@ + + @@ -39,4 +41,20 @@ + + + + + + + + + + + + + + + Modified: incubator/hcatalog/branches/branch-0.5/webhcat/svr/pom.xml URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/webhcat/svr/pom.xml?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/webhcat/svr/pom.xml (original) +++ incubator/hcatalog/branches/branch-0.5/webhcat/svr/pom.xml Wed Jan 2 18:10:48 2013 @@ -37,9 +37,40 @@ http://maven.apache.org + + + + + org.apache.hcatalog + hcatalog-core + ${hcatalog.version} + provided + + + org.apache.hadoop + hadoop-core + ${hadoop20.version} + provided + + + + + com.sun.jersey + jersey-core + ${jersey.version} + compile + com.sun.jersey - jersey-servlet + jersey-json + ${jersey.version} + compile + + + com.sun.jersey + jersey-server ${jersey.version} compile @@ -50,9 +81,15 @@ compile - org.apache.hcatalog - hcatalog-core - ${hcatalog.version} + org.apache.zookeeper + zookeeper + ${zookeeper.version} + compile + + + com.sun.jersey + jersey-json + ${jersey.version} compile @@ -68,6 +105,12 @@ compile + com.sun.jersey.contribs + wadl-resourcedoc-doclet + ${wadl-resourcedoc-doclet.version} + compile + + org.slf4j jul-to-slf4j ${slf4j.version} Added: incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_config.sh URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_config.sh?rev=1427888&view=auto ============================================================================== --- incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_config.sh (added) +++ incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_config.sh Wed Jan 2 18:10:48 2013 @@ -0,0 +1,94 @@ +#!/usr/bin/env 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 +# +# 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. + + +#==================================== +#Default config param values +#==================================== + +# The directory,file containing the running pid +PID_DIR=${WEBHCAT_PID_DIR:-.} +PID_FILE=${PID_DIR}/webhcat.pid + +PID_FILE=./webhcat.pid + +#default log directory +WEBHCAT_LOG_DIR=${WEBHCAT_LOG_DIR:-.} + +# The console error log +ERROR_LOG=${WEBHCAT_LOG_DIR}/webhcat-console-error.log + +# The console log +CONSOLE_LOG=${WEBHCAT_LOG_DIR}/webhcat-console.log + +# The name of the webhcat jar file +WEBHCAT_JAR=webhcat-0.5.0-SNAPSHOT.jar + +# How long to wait before testing that the process started correctly +SLEEP_TIME_AFTER_START=10 + +#================================================ +#See if the default configs have been overwritten +#================================================ + +#These parameters can be overriden by webhcat-env.sh +# the root of the WEBHCAT installation +export WEBHCAT_PREFIX=`dirname "$this"`/.. + +#check to see if the conf dir is given as an optional argument +if [ $# -gt 1 ] +then + if [ "--config" = "$1" ] + then + shift + confdir=$1 + shift + WEBHCAT_CONF_DIR=$confdir + fi +fi + +# Allow alternate conf dir location. +if [ -e "${WEBHCAT_PREFIX}/etc/webhcat/webhcat-env.sh" ]; then + DEFAULT_CONF_DIR=${WEBHCAT_PREFIX}/"etc/webhcat" +else + DEFAULT_CONF_DIR="/etc/webhcat" +fi +WEBHCAT_CONF_DIR="${WEBHCAT_CONF_DIR:-$DEFAULT_CONF_DIR}" + +#users can add various env vars to webhcat-env.sh in the conf +#rather than having to export them before running the command +if [ -f "${WEBHCAT_CONF_DIR}/webhcat-env.sh" ]; then + source "${WEBHCAT_CONF_DIR}/webhcat-env.sh" +fi + +#==================================== +#determine where hadoop is +#==================================== + +#check HADOOP_HOME and then check HADOOP_PREFIX +if [ -f ${HADOOP_HOME}/bin/hadoop ]; then + HADOOP_PREFIX=$HADOOP_HOME +#if this is an rpm install check for /usr/bin/hadoop +elif [ -f ${WEBHCAT_PREFIX}/bin/hadoop ]; then + HADOOP_PREFIX=$WEBHCAT_PREFIX +#otherwise see if HADOOP_PREFIX is defined +elif [ ! -f ${HADOOP_PREFIX}/bin/hadoop ]; then + echo "Hadoop not found." + exit 1 +fi Added: incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_server.sh URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_server.sh?rev=1427888&view=auto ============================================================================== --- incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_server.sh (added) +++ incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/bin/webhcat_server.sh Wed Jan 2 18:10:48 2013 @@ -0,0 +1,237 @@ +#!/usr/bin/env 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 +# +# 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. + +# +# Support functions +# + +# Follow symlinks on Linux and Darwin +function real_script_name() { + local base=$1 + local real + if readlink -f $base >/dev/null 2>&1; then + # Darwin/Mac OS X + real=`readlink -f $base` + fi + if [[ "$?" != "0" || -z "$real" ]]; then + # Linux + local bin=$(cd -P -- "$(dirname -- "$base")">/dev/null && pwd -P) + local script="$(basename -- "$base")" + real="$bin/$script" + fi + echo "$real" +} + +function usage() { + echo "usage: $0 [start|stop|foreground]" + echo " start Start the Webhcat Server" + echo " stop Stop the Webhcat Server" + echo " foreground Run the Webhcat Server in the foreground" + exit 1 +} + +# Print an error message and exit +function die() { + echo "webhcat: $@" 1>&2 + exit 1 +} + +# Print an message +function log() { + echo "webhcat: $@" +} + +# Find the webhcat jar +function find_jar_path() { + for dir in "." "build" "share/webhcat/svr/"; do + local jar="$base_dir/$dir/$WEBHCAT_JAR" + if [[ -f $jar ]]; then + echo $jar + break + fi + done +} + +# Find the webhcat classpath +function find_classpath() { + local classpath="" + for dir in "share/webhcat/svr/" "share/webhcat/svr/lib/" "conf" ; do + local path="$base_dir/$dir" + + if [[ -d $path ]]; then + for jar_or_conf in $path/*; do + if [[ -z "$classpath" ]]; then + classpath="$jar_or_conf" + else + classpath="$classpath:$jar_or_conf" + fi + done + fi + done + + if [[ -n "$WEBHCAT_CONF_DIR" ]]; then + if [[ -z "$classpath" ]]; then + classpath="$WEBHCAT_CONF_DIR" + else + classpath="$classpath:$WEBHCAT_CONF_DIR" + fi + fi + + # Append hcat classpath + local hcat_classpath + hcat_classpath=`hcat -classpath` + if [[ "$?" != "0" ]]; then + die "Unable to get the hcatalog classpath" + fi + echo "$classpath:$hcat_classpath" +} + +# Check if the pid is running +function check_pid() { + local pid=$1 + if ps -p $pid > /dev/null; then + return 0 + else + return 1 + fi +} + +# Start the webhcat server in the foreground +function foreground_webhcat() { + $start_cmd +} + +# Start the webhcat server in the background. Record the PID for +# later use. +function start_webhcat() { + if [[ -f $PID_FILE ]]; then + # Check if there is a server running + local pid=`cat $PID_FILE` + if check_pid $pid; then + die "already running on process $pid" + fi + fi + + log "starting ..." + log "$start_cmd" + nohup $start_cmd >>$CONSOLE_LOG 2>>$ERROR_LOG & + local pid=$! + + if [[ -z "${pid}" ]] ; then # we failed right off + die "failed to start. Check logs in " `dirname $ERROR_LOG` + fi + + sleep $SLEEP_TIME_AFTER_START + + if check_pid $pid; then + echo $pid > $PID_FILE + log "starting ... started." + else + die "failed to start. Check logs in " `dirname $ERROR_LOG` + fi +} + +# Stop a running server +function stop_webhcat() { + local pid + if [[ -f $PID_FILE ]]; then + # Check if there is a server running + local check=`cat $PID_FILE` + if check_pid $check; then + pid=$check + fi + fi + + if [[ -z "$pid" ]]; then + log "no running server found" + else + log "stopping ..." + kill $pid + sleep $SLEEP_TIME_AFTER_START + if check_pid $pid; then + die "failed to stop" + else + log "stopping ... stopped" + fi + fi +} + +# +# Build command line and run +# + +this=`real_script_name "${BASH_SOURCE-$0}"` +this_bin=`dirname $this` +base_dir="$this_bin/.." + +if [[ -f "$base_dir/libexec/webhcat_config.sh" ]]; then + . "$base_dir/libexec/webhcat_config.sh" +else + . "$this_bin/webhcat_config.sh" +fi + +JAR=`find_jar_path` +if [[ -z "$JAR" ]]; then + die "No webhcat jar found" +fi + +CLASSPATH=`find_classpath` +if [[ -z "$CLASSPATH" ]]; then + die "No classpath or jars found" +fi +CLASSPATH="$JAR:$CLASSPATH" + +if [[ -z "$HADOOP_CLASSPATH" ]]; then + export HADOOP_CLASSPATH="$CLASSPATH" +else + export HADOOP_CLASSPATH="$CLASSPATH:$HADOOP_CLASSPATH" +fi + +if [[ -z "$WEBHCAT_LOG4J" ]]; then + if [[ -f "$base_dir/conf/webhcat-log4j.properties" ]]; then + WEBHCAT_LOG4J="$base_dir/conf/webhcat-log4j.properties"; + elif [[ -f "$base_dir/conf/webhcat-log4j.properties" ]]; then + WEBHCAT_LOG4J="$base_dir/conf/webhcat-log4j.properties"; + else + WEBHCAT_LOG4J="webhcat-log4j.properties"; + fi +fi + +export HADOOP_USER_CLASSPATH_FIRST=true +export HADOOP_OPTS="-Dwebhcat.log.dir=$WEBHCAT_LOG_DIR -Dlog4j.configuration=$WEBHCAT_LOG4J" + +start_cmd="$HADOOP_PREFIX/bin/hadoop jar $JAR org.apache.hcatalog.templeton.Main " + + +cmd=$1 +case $cmd in + start) + start_webhcat + ;; + stop) + stop_webhcat + ;; + foreground) + foreground_webhcat + ;; + *) + usage + ;; +esac + +log "done" Added: incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-default.xml URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-default.xml?rev=1427888&view=auto ============================================================================== --- incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-default.xml (added) +++ incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-default.xml Wed Jan 2 18:10:48 2013 @@ -0,0 +1,213 @@ + + + + + + + + + + + + templeton.port + 50111 + The HTTP port for the main server. + + + + templeton.hadoop.conf.dir + ${env.HADOOP_CONF_DIR} + The path to the Hadoop configuration. + + + + templeton.jar + ${env.TEMPLETON_HOME}/templeton-0.1.0-dev.jar + The path to the Templeton jar file. + + + + templeton.libjars + ${env.TEMPLETON_HOME}/lib/zookeeper-3.3.4.jar + Jars to add to the classpath. + + + + templeton.override.jars + hdfs:///user/templeton/ugi.jar + + Jars to add the the HADOOP_CLASSPATH for all Map Reduce jobs. + This is a list of jars that must exist on hdfs that are added + to the Distributed Cache. + + + + + templeton.override.enabled + true + + Enable the override path in templeton.override.jars + + + + + templeton.streaming.jar + hdfs:///user/templeton/hadoop-streaming.jar + The hdfs path to the Hadoop streaming jar file. + + + + templeton.hadoop + ${env.HADOOP_PREFIX}/bin/hadoop + The path to the Hadoop executable. + + + + templeton.pig.archive + hdfs:///user/templeton/pig-0.10.0.tar.gz + The path to the Pig archive. + + + + templeton.pig.path + pig-0.10.0.tar.gz/pig-0.10.0/bin/pig + The path to the Pig executable. + + + + templeton.hcat + ${env.HCAT_PREFIX}/bin/hcat + The path to the hcatalog executable. + + + + templeton.hive.archive + hdfs:///user/templeton/hive-0.10.0.tar.gz + The path to the Hive archive. + + + + templeton.hive.path + hive-0.10.0.tar.gz/hive-0.10.0/bin/hive + The path to the Hive executable. + + + + templeton.hive.properties + hive.metastore.local=false,hive.metastore.uris=thrift://localhost:9933,hive.metastore.sasl.enabled=false + Properties to set when running hive. + + + + templeton.exec.encoding + UTF-8 + The encoding of the stdout and stderr data. + + + + templeton.exec.timeout + 10000 + + How long in milliseconds a program is allowed to run on the + Templeton box. + + + + + templeton.exec.max-procs + 16 + The maximum number of processes allowed to run at once. + + + + templeton.exec.max-output-bytes + 1048576 + + The maximum number of bytes from stdout or stderr stored in ram. + + + + + templeton.exec.envs + HADOOP_PREFIX,HADOOP_HOME,JAVA_HOME + The environment variables passed through to exec. + + + + templeton.zookeeper.hosts + 127.0.0.1:2181 + ZooKeeper servers, as comma separated host:port pairs + + + + templeton.zookeeper.session-timeout + 30000 + ZooKeeper session timeout in milliseconds + + + + templeton.callback.retry.interval + 10000 + How long to wait between callback retry attempts in milliseconds + + + + templeton.callback.retry.attempts + 5 + How many times to retry the callback + + + + templeton.storage.class + org.apache.hcatalog.templeton.tool.HDFSStorage + The class to use as storage + + + + templeton.storage.root + /templeton-hadoop + The path to the directory to use for storage + + + + templeton.hdfs.cleanup.interval + 43200000 + The maximum delay between a thread's cleanup checks + + + + templeton.hdfs.cleanup.maxage + 604800000 + The maximum age of a templeton job + + + + templeton.zookeeper.cleanup.interval + 43200000 + The maximum delay between a thread's cleanup checks + + + + templeton.zookeeper.cleanup.maxage + 604800000 + The maximum age of a templeton job + + + Added: incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-log4j.properties URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-log4j.properties?rev=1427888&view=auto ============================================================================== --- incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-log4j.properties (added) +++ incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/config/webhcat-log4j.properties Wed Jan 2 18:10:48 2013 @@ -0,0 +1,48 @@ +# 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. + +# +# templeton-log4j - configure the Templeton logging system + +# Define some default values that can be overridden by system properties +templeton.root.logger = DEBUG, standard +templeton.log.dir = . +templeton.log.file = templeton.log + +log4j.rootLogger = ${templeton.root.logger} + +# Logging Threshold +log4j.threshhold = DEBUG + +log4j.appender.standard = org.apache.log4j.DailyRollingFileAppender +log4j.appender.standard.File = ${templeton.log.dir}/${templeton.log.file} + +# Rollver at midnight +log4j.appender.DRFA.DatePattern = .yyyy-MM-dd + +log4j.appender.DRFA.layout = org.apache.log4j.PatternLayout + +log4j.appender.standard.layout = org.apache.log4j.PatternLayout +log4j.appender.standard.layout.conversionPattern = %-5p | %d{DATE} | %c | %m%n + +# Class logging settings +log4j.logger.com.sun.jersey = DEBUG +log4j.logger.com.sun.jersey.spi.container.servlet.WebComponent = ERROR +log4j.logger.org.apache.hadoop = INFO +log4j.logger.org.apache.hadoop.conf = WARN +log4j.logger.org.apache.zookeeper = WARN +log4j.logger.org.eclipse.jetty = INFO Modified: incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/java/org/apache/hcatalog/templeton/AppConfig.java URL: http://svn.apache.org/viewvc/incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/java/org/apache/hcatalog/templeton/AppConfig.java?rev=1427888&r1=1427887&r2=1427888&view=diff ============================================================================== --- incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/java/org/apache/hcatalog/templeton/AppConfig.java (original) +++ incubator/hcatalog/branches/branch-0.5/webhcat/svr/src/main/java/org/apache/hcatalog/templeton/AppConfig.java Wed Jan 2 18:10:48 2013 @@ -39,11 +39,11 @@ import org.apache.hcatalog.templeton.too * * The Templeton specific configuration is split into two layers * - * 1. templeton-default.xml - All the configuration variables that + * 1. webhcat-default.xml - All the configuration variables that * Templeton needs. These are the defaults that ship with the app * and should only be changed be the app developers. * - * 2. templeton-site.xml - The (possibly empty) configuration that the + * 2. webhcat-site.xml - The (possibly empty) configuration that the * system administrator can set variables for their Hadoop cluster. * * The configuration files are loaded in this order with later files @@ -72,8 +72,8 @@ public class AppConfig extends Configura public static final String TEMPLETON_HOME_VAR = "TEMPLETON_HOME"; public static final String[] TEMPLETON_CONF_FILENAMES = { - "templeton-default.xml", - "templeton-site.xml" + "webhcat-default.xml", + "webhcat-site.xml" }; public static final String PORT = "templeton.port";