2018-11-13 12:38:37 -05:00
|
|
|
# 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.
|
|
|
|
|
2014-12-19 18:53:19 -05:00
|
|
|
language: java
|
|
|
|
|
2017-12-12 20:14:44 -05:00
|
|
|
# On 12-12-2017, Travis updated their trusty image, which caused integration tests to fail.
|
|
|
|
# The group: config instructs Travis to use the previous trusty image.
|
2018-08-30 12:56:26 -04:00
|
|
|
# Please see https://github.com/apache/incubator-druid/pull/5155 for more information.
|
2018-08-11 01:03:36 -04:00
|
|
|
sudo: false
|
2017-09-06 05:51:06 -04:00
|
|
|
dist: trusty
|
2017-12-12 20:14:44 -05:00
|
|
|
group: deprecated-2017Q4
|
2017-07-19 02:19:33 -04:00
|
|
|
|
2014-12-19 18:53:19 -05:00
|
|
|
jdk:
|
2019-05-10 20:09:55 -04:00
|
|
|
- openjdk8
|
2015-01-07 18:07:14 -05:00
|
|
|
|
2015-08-07 21:05:25 -04:00
|
|
|
cache:
|
|
|
|
directories:
|
2017-05-20 14:42:44 -04:00
|
|
|
- $HOME/.m2
|
2018-07-31 15:56:57 -04:00
|
|
|
|
2017-05-31 21:27:34 -04:00
|
|
|
matrix:
|
|
|
|
include:
|
2018-09-25 17:39:24 -04:00
|
|
|
# license checks
|
|
|
|
- env:
|
|
|
|
- NAME="license checks"
|
|
|
|
install: true
|
2019-01-29 14:35:22 -05:00
|
|
|
script: MAVEN_OPTS='-Xmx3000m' mvn clean verify -Prat -DskipTests -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -Drat.consoleOutput=true
|
2018-09-25 17:39:24 -04:00
|
|
|
|
2017-06-26 21:51:48 -04:00
|
|
|
# strict compilation
|
2018-08-11 01:03:36 -04:00
|
|
|
- env:
|
2017-11-20 23:27:41 -05:00
|
|
|
- NAME="strict compilation"
|
2017-05-31 21:27:34 -04:00
|
|
|
install: true
|
2017-06-26 21:51:48 -04:00
|
|
|
# Strict compilation requires more than 2 GB
|
2018-08-11 01:03:36 -04:00
|
|
|
script: MAVEN_OPTS='-Xmx3000m' mvn clean -Pstrict -pl '!benchmarks' compile test-compile -B --fail-at-end
|
2017-06-26 21:51:48 -04:00
|
|
|
|
2019-04-07 23:12:23 -04:00
|
|
|
# packaging check
|
|
|
|
- env:
|
|
|
|
- NAME="packaging check"
|
|
|
|
install: true
|
|
|
|
script: MAVEN_OPTS='-Xmx3000m' mvn -DskipTests -Dforbiddenapis.skip=true -Dcheckstyle.skip=true -Dpmd.skip=true -Dmaven.javadoc.skip=true -pl '!benchmarks' -B --fail-at-end clean install -Pdist
|
|
|
|
|
2017-06-26 21:51:48 -04:00
|
|
|
# processing module test
|
2018-08-11 01:03:36 -04:00
|
|
|
- env:
|
2017-11-20 23:27:41 -05:00
|
|
|
- NAME="processing module test"
|
2018-08-11 01:03:36 -04:00
|
|
|
install: MAVEN_OPTS='-Xmx3000m' mvn install -q -ff -DskipTests -B
|
|
|
|
before_script: unset _JAVA_OPTIONS
|
|
|
|
script:
|
|
|
|
# Set MAVEN_OPTS for Surefire launcher
|
|
|
|
- MAVEN_OPTS='-Xmx512m' mvn test -B -pl processing
|
|
|
|
- sh -c "dmesg | egrep -i '(oom|out of memory|kill process|killed).*' -C 1 || exit 0"
|
|
|
|
- free -m
|
2017-06-26 21:51:48 -04:00
|
|
|
|
2018-08-02 11:20:25 -04:00
|
|
|
# processing module tests with SQL Compatibility enabled
|
2018-08-11 01:03:36 -04:00
|
|
|
- env:
|
2018-08-02 11:20:25 -04:00
|
|
|
- NAME="processing module test with SQL Compatibility"
|
2018-08-11 01:03:36 -04:00
|
|
|
install: MAVEN_OPTS='-Xmx3000m' mvn install -q -ff -DskipTests -B
|
|
|
|
before_script: unset _JAVA_OPTIONS
|
|
|
|
script:
|
|
|
|
# Set MAVEN_OPTS for Surefire launcher
|
|
|
|
- MAVEN_OPTS='-Xmx512m' mvn test -B -Ddruid.generic.useDefaultValueForNull=false -pl processing
|
|
|
|
- sh -c "dmesg | egrep -i '(oom|out of memory|kill process|killed).*' -C 1 || exit 0"
|
|
|
|
- free -m
|
2018-08-02 11:20:25 -04:00
|
|
|
|
2017-11-20 23:27:41 -05:00
|
|
|
# server module test
|
2018-08-11 01:03:36 -04:00
|
|
|
- env:
|
2017-11-20 23:27:41 -05:00
|
|
|
- NAME="server module test"
|
2018-08-11 01:03:36 -04:00
|
|
|
install: MAVEN_OPTS='-Xmx3000m' mvn install -q -ff -DskipTests -B
|
|
|
|
before_script: unset _JAVA_OPTIONS
|
|
|
|
script:
|
|
|
|
# Set MAVEN_OPTS for Surefire launcher
|
|
|
|
- MAVEN_OPTS='-Xmx512m' mvn test -B -pl server
|
2017-11-20 23:27:41 -05:00
|
|
|
|
2018-08-02 11:20:25 -04:00
|
|
|
# server module test with SQL Compatibility enabled
|
2018-08-11 01:03:36 -04:00
|
|
|
- env:
|
2018-08-02 11:20:25 -04:00
|
|
|
- NAME="server module test with SQL Compatibility enabled"
|
2018-08-11 01:03:36 -04:00
|
|
|
install: MAVEN_OPTS='-Xmx3000m' mvn install -q -ff -DskipTests -B
|
|
|
|
before_script: unset _JAVA_OPTIONS
|
|
|
|
script:
|
|
|
|
# Set MAVEN_OPTS for Surefire launcher
|
|
|
|
- MAVEN_OPTS='-Xmx512m' mvn test -B -pl server -Ddruid.generic.useDefaultValueForNull=false
|
2018-08-02 11:20:25 -04:00
|
|
|
|
|
|
|
|
2017-11-20 23:27:41 -05:00
|
|
|
# other modules test
|
2018-08-11 01:03:36 -04:00
|
|
|
- env:
|
2017-11-20 23:27:41 -05:00
|
|
|
- NAME="other modules test"
|
2018-03-21 18:36:54 -04:00
|
|
|
- AWS_REGION=us-east-1 # set a aws region for unit tests
|
2018-08-11 01:03:36 -04:00
|
|
|
install: MAVEN_OPTS='-Xmx3000m' mvn install -q -ff -DskipTests -B
|
|
|
|
before_script: unset _JAVA_OPTIONS
|
|
|
|
script:
|
|
|
|
# Set MAVEN_OPTS for Surefire launcher
|
|
|
|
- MAVEN_OPTS='-Xmx512m' mvn test -B -pl '!processing,!server'
|
|
|
|
- sh -c "dmesg | egrep -i '(oom|out of memory|kill process|killed).*' -C 1 || exit 0"
|
|
|
|
- free -m
|
2017-06-26 21:51:48 -04:00
|
|
|
|
2018-08-02 11:20:25 -04:00
|
|
|
# other modules test with SQL Compatibility enabled
|
2018-08-11 01:03:36 -04:00
|
|
|
- env:
|
2018-08-02 11:20:25 -04:00
|
|
|
- NAME="other modules test with SQL Compatibility"
|
|
|
|
- AWS_REGION=us-east-1 # set a aws region for unit tests
|
2018-08-11 01:03:36 -04:00
|
|
|
install: MAVEN_OPTS='-Xmx3000m' mvn install -q -ff -DskipTests -B
|
|
|
|
before_script: unset _JAVA_OPTIONS
|
|
|
|
script:
|
|
|
|
# Set MAVEN_OPTS for Surefire launcher
|
|
|
|
- MAVEN_OPTS='-Xmx512m' mvn test -B -Ddruid.generic.useDefaultValueForNull=false -pl '!processing,!server'
|
|
|
|
- sh -c "dmesg | egrep -i '(oom|out of memory|kill process|killed).*' -C 1 || exit 0"
|
|
|
|
- free -m
|
2018-08-02 11:20:25 -04:00
|
|
|
|
2017-06-26 21:51:48 -04:00
|
|
|
# run integration tests
|
2017-05-31 21:27:34 -04:00
|
|
|
- sudo: required
|
|
|
|
services:
|
|
|
|
- docker
|
|
|
|
env:
|
2018-09-19 12:56:15 -04:00
|
|
|
- NAME="integration test part 1"
|
|
|
|
- DOCKER_IP=127.0.0.1
|
2017-05-31 21:27:34 -04:00
|
|
|
install:
|
|
|
|
# Only errors will be shown with the -q option. This is to avoid generating too many logs which make travis build failed.
|
2017-06-26 21:51:48 -04:00
|
|
|
- mvn install -q -ff -DskipTests -B
|
2017-05-31 21:27:34 -04:00
|
|
|
script:
|
|
|
|
- $TRAVIS_BUILD_DIR/ci/travis_script_integration.sh
|
2017-11-10 17:07:37 -05:00
|
|
|
after_failure:
|
|
|
|
- for v in ~/shared/logs/*.log ; do
|
|
|
|
echo $v logtail ======================== ; tail -100 $v ;
|
|
|
|
done
|
|
|
|
- for v in broker middlemanager overlord router coordinator historical ; do
|
|
|
|
echo $v dmesg ======================== ;
|
|
|
|
docker exec -it druid-$v sh -c 'dmesg | tail -3' ;
|
|
|
|
done
|
2018-09-19 12:56:15 -04:00
|
|
|
|
|
|
|
# run integration tests
|
|
|
|
- sudo: required
|
|
|
|
services:
|
|
|
|
- docker
|
|
|
|
env:
|
|
|
|
- NAME="integration test part 2"
|
|
|
|
- DOCKER_IP=127.0.0.1
|
|
|
|
install:
|
|
|
|
# Only errors will be shown with the -q option. This is to avoid generating too many logs which make travis build failed.
|
|
|
|
- mvn install -q -ff -DskipTests -B
|
|
|
|
script:
|
|
|
|
- $TRAVIS_BUILD_DIR/ci/travis_script_integration_part2.sh
|
|
|
|
after_failure:
|
|
|
|
- for v in ~/shared/logs/*.log ; do
|
|
|
|
echo $v logtail ======================== ; tail -100 $v ;
|
|
|
|
done
|
|
|
|
- for v in broker middlemanager overlord router coordinator historical ; do
|
|
|
|
echo $v dmesg ======================== ;
|
|
|
|
docker exec -it druid-$v sh -c 'dmesg | tail -3' ;
|
|
|
|
done
|