Make hadoop version configurable in test

This commit is contained in:
Lee moon soo 2015-06-03 13:08:12 +09:00
parent bb47e81b12
commit b5f734388d
3 changed files with 22 additions and 20 deletions

View file

@ -22,14 +22,14 @@ before_install:
- "sh -e /etc/init.d/xvfb start"
install:
- mvn package -DskipTests -B
- mvn package -DskipTests -Phadoop-2.3 -B
before_script:
- mvn package -Pbuild-distr -B
- ./testing/startSparkCluster.sh 1.1.1
- mvn package -Pbuild-distr -Phadoop-2.3 -B
- ./testing/startSparkCluster.sh 1.1.1 2.3
script:
- mvn verify -Pusing-packaged-distr -B
- mvn verify -Pusing-packaged-distr -Phadoop-2.3 -B
after_failure:
- cat target/rat.txt
@ -38,7 +38,7 @@ after_failure:
- cat zeppelin-distribution/target/zeppelin-*-SNAPSHOT/zeppelin-*-SNAPSHOT/logs/zeppelin*.out
after_script:
- ./testing/stopSparkCluster.sh 1.1.1
- ./testing/stopSparkCluster.sh 1.1.1 2.3
notifications:
slack:

View file

@ -1,4 +1,4 @@
#!/bin/sh
#!/bin/bash
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
@ -17,21 +17,22 @@
#
if [ $# -ne 1 ]; then
echo "usage) $0 [spark version]"
echo " eg) $0 1.3.1"
if [ $# -ne 2 ]; then
echo "usage) $0 [spark version] [hadoop version]"
echo " eg) $0 1.3.1 2.6"
exit 1
fi
SPARK_VERSION="${1}"
HADOOP_VERSION="${2}"
if [ ! -d "spark-${SPARK_VERSION}-bin-hadoop2.3" ]; then
wget -q http://www.us.apache.org/dist/spark/spark-${SPARK_VERSION}/spark-${SPARK_VERSION}-bin-hadoop2.3.tgz
tar zxf spark-${SPARK_VERSION}-bin-hadoop2.3.tgz
if [ ! -d "spark-${SPARK_VERSION}-bin-hadoop${HADOOP_VERSION}" ]; then
wget -q http://www.us.apache.org/dist/spark/spark-${SPARK_VERSION}/spark-${SPARK_VERSION}-bin-hadoop${HADOOP_VERSION}.tgz
tar zxf spark-${SPARK_VERSION}-bin-hadoop${HADOOP_VERSION}.tgz
fi
# start
export SPARK_MASTER_PORT=7071
export SPARK_MASTER_WEBUI_PORT=7072
./spark-${SPARK_VERSION}-bin-hadoop2.3/sbin/start-master.sh
./spark-${SPARK_VERSION}-bin-hadoop2.3/sbin/start-slave.sh 1 `hostname`:${SPARK_MASTER_PORT}
./spark-${SPARK_VERSION}-bin-hadoop${HADOOP_VERSION}/sbin/start-master.sh
./spark-${SPARK_VERSION}-bin-hadoop${HADOOP_VERSION}/sbin/start-slave.sh 1 `hostname`:${SPARK_MASTER_PORT}

View file

@ -1,4 +1,4 @@
#!/bin/sh#
#!/bin/bash#
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
@ -16,15 +16,16 @@
# limitations under the License.
#
if [ $# -ne 1 ]; then
echo "usage) $0 [spark version]"
echo " eg) $0 1.3.1"
if [ $# -ne 2 ]; then
echo "usage) $0 [spark version] [hadoop version]"
echo " eg) $0 1.3.1 2.6"
exit 1
fi
SPARK_VERSION="${1}"
HADOOP_VERSION="${2}"
./spark-${SPARK_VERSION}-bin-hadoop2.3/sbin/spark-daemon.sh stop org.apache.spark.deploy.worker.Worker 1
./spark-${SPARK_VERSION}-bin-hadoop2.3/sbin/stop-master.sh
./spark-${SPARK_VERSION}-bin-hadoop${HADOOP_VERSION}/sbin/spark-daemon.sh stop org.apache.spark.deploy.worker.Worker 1
./spark-${SPARK_VERSION}-bin-hadoop${HADOOP_VERSION}/sbin/stop-master.sh