This is an automated email from the ASF dual-hosted git repository. stoty pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/phoenix.git
The following commit(s) were added to refs/heads/master by this push: new 56b5c01 PHOENIX-6056 Migrate from builds.apache.org by August 15 56b5c01 is described below commit 56b5c01bf35ebc76bfe66040afb742eb28a2d936 Author: Istvan Toth <st...@apache.org> AuthorDate: Tue Aug 11 13:12:58 2020 +0200 PHOENIX-6056 Migrate from builds.apache.org by August 15 Jenkinsfile for multibranch job --- Jenkinsfile | 103 ++++++++++++++++++++++++++++++++++++++++++++++ dev/rebuild_hbase.sh | 1 + dev/test-patch.properties | 2 +- 3 files changed, 105 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..a9b094b --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,103 @@ +/* + * 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. + */ + +pipeline { + agent { + label 'Hadoop' + } + + options { + buildDiscarder(logRotator(daysToKeepStr: '30')) + timeout(time: 6, unit: 'HOURS') + timestamps() + } + + stages { + stage('MatrixBuild') { + matrix { + agent any + + axes { + axis { + name 'HBASE_PROFILE' + values '2.1', '2.2', '2.3' + } + } + + tools { + maven "Maven (latest)" + jdk "JDK 1.8 (latest)" + } + + environment { + MAVEN_OPTS = '-Xmx3G' + } + + stages { + + stage('RebuildHBase') { + environment { + HBASE_VERSION = sh(returnStdout: true, script: "mvn help:evaluate -Dhbase.profile=${HBASE_PROFILE} -Dartifact=org.apache.phoenix:phoenix-core -Dexpression=hbase.version -q -DforceStdout").trim() + } + when { + not { + environment name: 'HBASE_PROFILE', value: '2.1' + } + } + steps { + sh "dev/rebuild_hbase.sh ${HBASE_VERSION}" + } + } + + stage('BuildAndTest') { + steps { + sh "mvn clean verify -Dhbase.profile=${HBASE_PROFILE} -B" + } + post { + always { + junit '**/target/surefire-reports/TEST-*.xml' + junit '**/target/failsafe-reports/TEST-*.xml' + } + } + } + } + + post { + always { + emailext( + subject: "Apache-Phoenix | ${BRANCH_NAME} | HBase ${HBASE_PROFILE} | Build ${BUILD_DISPLAY_NAME} ${currentBuild.currentResult}", + to: 'commits@phoenix.apache.org', + replyTo: 'commits@phoenix.apache.org', + mimeType: 'text/html', + recipientProviders: [ + [$class: "DevelopersRecipientProvider"], + [$class: 'CulpritsRecipientProvider'], + [$class: 'RequesterRecipientProvider']], + body: """ +<a href="http://phoenix.apache.org"><img src='http://phoenix.apache.org/images/phoenix-logo-small.png'/></a> +<br><b>${BRANCH_NAME}</b> branch <b> HBase ${HBASE_PROFILE} </b> build ${BUILD_DISPLAY_NAME} status <b>${currentBuild.currentResult}</b><hr/> +<b>Build ${BUILD_DISPLAY_NAME}</b> ${BUILD_URL} +<hr/> +""" + ) + } + } + } + } + } +} \ No newline at end of file diff --git a/dev/rebuild_hbase.sh b/dev/rebuild_hbase.sh index e89984e..a47b938 100755 --- a/dev/rebuild_hbase.sh +++ b/dev/rebuild_hbase.sh @@ -1,3 +1,4 @@ +#!/usr/bin/env bash # The name of the Apache Hbase source file HBASE_SOURCE_NAME="hbase-$1-src.tar.gz" # The relative path on the ASF mirrors for the Hbase source file diff --git a/dev/test-patch.properties b/dev/test-patch.properties index 7d8ae20..b26bcef 100644 --- a/dev/test-patch.properties +++ b/dev/test-patch.properties @@ -27,7 +27,7 @@ MAX_LINE_LENGTH=100 # All supported branches for testing with precommit build # be sure to consider branch name prefixes in the order, ie, 4.x should appear # before 4 since the latter is a prefix -BRANCH_NAMES="4.x-HBase-1.3 4.x-HBase-1.4 4.x-HBase-1.5 4.x-cdh5.11 4.x-cdh5.11.2 4.x-cdh5.12 4.x-cdh5.13 4.x-cdh5.14 4.14-HBase-1.3 4.14-HBase-1.4 4.14-cdh5.11 4.14-cdh5.12 4.14-cdh5.13 4.14-cdh5.14 4.x master" +BRANCH_NAMES="4.x master" # All supported Hadoop versions that we want to test the compilation with