-
Bug
-
Resolution: Incomplete
-
Minor
-
None
-
Jenkins ver. 2.33
On this pipeline
node {
timeout(time: 30, unit: 'SECONDS') {
environment = 'staging'
stage 'Retrieving repositories'
parallel getDBUri: {
// Obtain pipeline and DB_URI using a script in the pipeline
dir('pipelineRepo') {
git ...
pipeline = load 'pipeline.groovy'
sh 'pwd'
withCredentials([
[
$class: 'StringBinding',
credentialsId: 'herokuToken',
variable: 'token'
]
]) {
env.PG_URI = pipeline.herokuVariable( 'novus-'+environment, 'DB_URI', env.token )
}
}
}, getScript: {
// Obtain script to execute and install dependencies
dir('scriptRepo') {
git ..
withCredentials([
[
$class: 'StringBinding',
credentialsId: 'NpmToken',
variable: 'NPM_TOKEN'
]
]) {
sh 'echo "//registry.npmjs.org/:_authToken='+env.NPM_TOKEN+'" > ~/.npmrc'
sh 'npm install --production && npm prune --production'
sh 'unlink ~/.npmrc'
}
}
},
failFast: true
}
The timeout is honoured but not executed correctly
[Pipeline] [getDBUri] } Cancelling nested steps due to timeout [getScript] Sending interrupt signal to process [getScript] Sending interrupt signal to process Body did not finish within grace period; terminating with extreme prejudice [Pipeline] // parallel [Pipeline] } [Pipeline] [getScript] } [Pipeline] // timeout [Pipeline] } [Pipeline] // node Aborted by admin [Pipeline] [getScript] } Click here to forcibly terminate running steps Terminating withCredentials Click here to forcibly kill entire build Hard kill! Finished: ABORTED
Neither the manual aborting worked at the beginning I had to use "Click here to forcibly kill entire build", the timeout option should have an option to kill the build in the worst case
- relates to
-
JENKINS-51928 Timeout is caught by the most internal try-catch, but should be caught by the try-catch that surrounds the timeout step
-
- Resolved
-