Retry Jenkins CI tests up to 3 times to improve reliability (#3769)
This commit is contained in:
parent
ea99b53d8e
commit
7a7269e983
2
Jenkinsfile
vendored
2
Jenkinsfile
vendored
@ -74,6 +74,7 @@ def buildPlatformCmake(buildName, conf, nodeReq, dockerTarget) {
|
||||
def test_suite = conf["withGpu"] ? (conf["multiGpu"] ? "mgpu" : "gpu") : "cpu"
|
||||
// Build node - this is returned result
|
||||
node(nodeReq) {
|
||||
retry(3) {
|
||||
unstash name: 'srcs'
|
||||
echo """
|
||||
|===== XGBoost CMake build =====
|
||||
@ -99,4 +100,5 @@ def buildPlatformCmake(buildName, conf, nodeReq, dockerTarget) {
|
||||
"""
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -52,6 +52,7 @@ pipeline {
|
||||
label 'linux && cpu && restricted'
|
||||
}
|
||||
steps {
|
||||
retry(3) {
|
||||
unstash name: 'srcs'
|
||||
script {
|
||||
def commit_id = "${GIT_COMMIT}"
|
||||
@ -68,6 +69,7 @@ pipeline {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Jenkins: Build artifacts') {
|
||||
steps {
|
||||
@ -95,6 +97,7 @@ def buildPlatformCmake(buildName, conf, nodeReq, dockerTarget) {
|
||||
}
|
||||
// Build node - this is returned result
|
||||
node(nodeReq) {
|
||||
retry(3) {
|
||||
unstash name: 'srcs'
|
||||
echo """
|
||||
|===== XGBoost CMake build =====
|
||||
@ -113,4 +116,5 @@ def buildPlatformCmake(buildName, conf, nodeReq, dockerTarget) {
|
||||
"""
|
||||
archiveArtifacts artifacts: "${distDir}/**/*.*", allowEmptyArchive: true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user