summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Kocoloski <kocolosk@apache.org>2022-01-18 14:45:13 -0500
committerAdam Kocoloski <kocolosk@apache.org>2022-01-19 21:45:35 -0500
commitbf14a1c3793fdc2db206f602e9cbb45492a399e9 (patch)
treeec2563c4fcc324be20811230188f3e485bb24549
parentbac9af932551b2f1bf5815ae8ca5cb9d517274a6 (diff)
downloadcouchdb-bf14a1c3793fdc2db206f602e9cbb45492a399e9.tar.gz
Use error() step to signal build failure
-rw-r--r--build-aux/Jenkinsfile.full10
1 files changed, 4 insertions, 6 deletions
diff --git a/build-aux/Jenkinsfile.full b/build-aux/Jenkinsfile.full
index 124c8b106..77bc26a42 100644
--- a/build-aux/Jenkinsfile.full
+++ b/build-aux/Jenkinsfile.full
@@ -134,8 +134,6 @@ def generateNativeStage(platform) {
}
}
catch (err) {
- echo "Build failed: {$err}"
- currentBuild.result = 'FAILURE'
sh 'ls -l ${WORKSPACE}'
withEnv([
'HOME='+pwd(),
@@ -147,6 +145,7 @@ def generateNativeStage(platform) {
sh '${MAKE} build-report'
}
}
+ error("Build step failed with error: ${err.getMessage()}")
}
finally {
junit '**/.eunit/*.xml, **/_build/*/lib/couchdbtest/*.xml, **/src/mango/nosetests.xml, **/test/javascript/junit.xml'
@@ -186,13 +185,12 @@ def generateContainerStage(platform) {
}
}
catch (err) {
- echo "Build failed: {$err}"
- currentBuild.result = 'FAILURE'
sh 'ls -l ${WORKSPACE}'
dir( "${platform}/build" ) {
sh 'ls -l'
sh 'make build-report'
}
+ error("Build step failed with error: ${err.getMessage()}")
}
finally {
junit '**/.eunit/*.xml, **/_build/*/lib/couchdbtest/*.xml, **/src/mango/nosetests.xml, **/test/javascript/junit.xml'
@@ -218,9 +216,8 @@ def generateContainerStage(platform) {
archiveArtifacts artifacts: 'pkgs/**', fingerprint: true, onlyIfSuccessful: true
}
catch (err) {
- echo "Packaging failed: {$err}"
- currentBuild.result = 'FAILURE'
sh 'ls -l ${WORKSPACE}'
+ error("Build step failed with error: ${err.getMessage()}")
}
finally {
sh 'rm -rf ${WORKSPACE}/*'
@@ -279,6 +276,7 @@ pipeline {
spidermonkey = '78'
}
options {
+ // TODO start this timeout _after_ the agent has been acquired if possible
timeout(time: 15, unit: "MINUTES")
}
steps {