You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by ma...@apache.org on 2020/04/04 19:45:59 UTC
[logging-log4j2] branch release-2.x updated: Backport Jenkinsfile
updates from master
This is an automated email from the ASF dual-hosted git repository.
mattsicker pushed a commit to branch release-2.x
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git
The following commit(s) were added to refs/heads/release-2.x by this push:
new f618693 Backport Jenkinsfile updates from master
f618693 is described below
commit f618693a7cab1f350fa001d8e9c59653ba65695b
Author: Matt Sicker <bo...@gmail.com>
AuthorDate: Sat Apr 4 14:45:16 2020 -0500
Backport Jenkinsfile updates from master
This includes snapshot deployments and updated notification settings.
---
Jenkinsfile | 84 +++++++++++++++++++++++------------
toolchains-jenkins-ubuntu.xml | 101 ------------------------------------------
toolchains-jenkins-win.xml | 101 ------------------------------------------
3 files changed, 55 insertions(+), 231 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 8510648..cc884bb 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -34,28 +34,16 @@ pipeline {
jdk 'JDK 1.8 (latest)'
maven 'Maven 3 (latest)'
}
- steps {
- sh 'mvn -B -fn -t toolchains-jenkins-ubuntu.xml -Djenkins -V clean install'
+ environment {
+ LANG = 'en_US.UTF-8'
}
- post {
- always {
- archiveArtifacts artifacts: '**/*.jar', fingerprint: true
- junit '**/*-reports/*.xml'
- recordIssues enabledForFailure: true,
- tool: mavenConsole(),
- referenceJobName: 'log4j/release-2.x'
- recordIssues enabledForFailure: true,
- tool: errorProne(),
- referenceJobName: 'log4j/release-2.x'
- recordIssues enabledForFailure: true,
- tool: java(),
- sourceCodeEncoding: 'UTF-8',
- referenceJobName: 'log4j/release-2.x'
- recordIssues enabledForFailure: true,
- tool: taskScanner(includePattern: '**/*.java', excludePattern: 'target/**', highTags: 'FIXME', normalTags: 'TODO'),
- sourceCodeEncoding: 'UTF-8',
- referenceJobName: 'log4j/release-2.x'
- }
+ steps {
+ sh 'mvn -B -fn -Djenkins -V clean install deploy'
+ junit '**/*-reports/*.xml'
+ archiveArtifacts artifacts: '**/*.jar', fingerprint: true
+ recordIssues sourceCodeEncoding: 'UTF-8', referenceJobName: 'log4j/release-2.x',
+ tools: [mavenConsole(), errorProne(), java(), // junitParser() // TODO: compare with junit step
+ taskScanner(highTags: 'FIXME', normalTags: 'TODO', includePattern: '**/*.java', excludePattern: '*/target/**')]
}
}
stage('Windows') {
@@ -64,16 +52,15 @@ pipeline {
jdk 'JDK 1.8 (latest)'
maven 'Maven 3 (latest)'
}
+ environment {
+ LANG = 'en_US.UTF-8'
+ }
steps {
bat '''
if exist %userprofile%\\.embedmongo\\ rd /s /q %userprofile%\\.embedmongo
- mvn -B -fn -t toolchains-jenkins-win.xml -Dfile.encoding=UTF-8 -V clean install
+ mvn -B -fn -Dfile.encoding=UTF-8 -V clean install
'''
- }
- post {
- always {
- junit '**/*-reports/*.xml'
- }
+ junit '**/*-reports/*.xml'
}
}
}
@@ -81,10 +68,49 @@ pipeline {
}
post {
regression {
- slackSend channel: 'logging', message: "Regression detected in ${env.BUILD_URL}", color: 'danger'
+ slackSend channel: 'logging',
+ color: 'warning',
+ message: ":disappear: Regression detected in ${env.BUILD_URL}"
+ mail to: 'notifications@logging.apache.org',
+ replyTo: 'dev@logging.apache.org',
+ subject: "Regression in Jenkins build of ${env.JOB_NAME} (${env.BUILD_NUMBER})",
+ body: """
+There is a new regression detected in ${env.JOB_NAME}.
+
+Build: ${env.BUILD_URL}
+Logs: ${env.BUILD_URL}console
+Tests: ${env.BUILD_URL}testReport/
+Changes: ${env.BUILD_URL}changes
+"""
}
fixed {
- slackSend channel: 'logging', message: "Build back to normal: ${env.BUILD_URL}", color: 'good'
+ slackSend channel: 'logging',
+ color: 'good',
+ message: ":beer_parrot: Build back to normal: ${env.BUILD_URL}"
+ mail to: 'notifications@logging.apache.org',
+ replyTo: 'dev@logging.apache.org',
+ subject: "Jenkins build of ${env.JOB_NAME} (${env.BUILD_NUMBER}) back to normal",
+ body: "See ${env.BUILD_URL} for more details."
+ }
+ failure {
+ slackSend channel: 'logging',
+ color: 'danger',
+ message: ":doh: Build failed: ${env.BUILD_URL}"
+ mail to: 'notifications@logging.apache.org',
+ replyTo: 'dev@logging.apache.org',
+ subject: "Build failure in Jenkins build of ${env.JOB_NAME} (${env.BUILD_NUMBER})",
+ body: """
+There is a build failure in ${env.JOB_NAME}.
+
+Build: ${env.BUILD_URL}
+Logs: ${env.BUILD_URL}console
+Changes: ${env.BUILD_URL}changes
+"""
+ }
+ unstable {
+ slackSend channel: 'logging',
+ color: 'warning',
+ message: ":sadpanda: Build still unstable: ${env.BUILD_URL}"
}
}
}
diff --git a/toolchains-jenkins-ubuntu.xml b/toolchains-jenkins-ubuntu.xml
deleted file mode 100644
index 09898d7..0000000
--- a/toolchains-jenkins-ubuntu.xml
+++ /dev/null
@@ -1,101 +0,0 @@
-<?xml version="1.0" encoding="UTF8"?>
-<!--
- ~ 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.
- -->
-<toolchains>
- <!-- JDK toolchains -->
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>1.8</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>/home/jenkins/tools/java/latest1.8</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>9</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>/home/jenkins/tools/java/latest1.9</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>10</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>/home/jenkins/tools/java/latest10</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>11</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>/home/jenkins/tools/java/latest11/</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>12</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>/home/jenkins/tools/java/latest12/</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>13</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>/home/jenkins/tools/java/latest13/</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>14</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>/home/jenkins/tools/java/latest14/</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>15</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>/home/jenkins/tools/java/latest15/</jdkHome>
- </configuration>
- </toolchain>
- <!-- other toolchains -->
-</toolchains>
diff --git a/toolchains-jenkins-win.xml b/toolchains-jenkins-win.xml
deleted file mode 100644
index df01b39..0000000
--- a/toolchains-jenkins-win.xml
+++ /dev/null
@@ -1,101 +0,0 @@
-<?xml version="1.0" encoding="UTF8"?>
-<!--
- ~ 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
- ~
- ~ https://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.
- -->
-<toolchains>
- <!-- JDK toolchains -->
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>1.8</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>F:\jenkins\tools\java\latest1.8</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>9</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>F:\jenkins\tools\java\latest9</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>10</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>F:\jenkins\tools\java\latest10</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>11</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>F:\jenkins\tools\java\latest11</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>12</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>F:\jenkins\tools\java\latest12</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>13</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>F:\jenkins\tools\java\latest13</jdkHome>
- </configuration>
- </toolchain>
- <toolchain>
- <type>jdk</type>
- <provides>
- <version>14</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>F:\jenkins\tools\java\latest14</jdkHome>
- </configuration>
- </toolchain>
- <!--toolchain>
- <type>jdk</type>
- <provides>
- <version>15</version>
- <vendor>sun</vendor>
- </provides>
- <configuration>
- <jdkHome>F:\jenkins\tools\java\latest15</jdkHome>
- </configuration>
- </toolchain-->
- <!-- other toolchains -->
-</toolchains>