未验证 提交 3652b9da 编写于 作者: Q quicksilver 提交者: GitHub

Add timeout delay for e2e test jenkins pipeline (#6342)

Signed-off-by: Nquicksilver <zhifeng.zhang@zilliz.com>
上级 8f1ec25d
#!/usr/bin/env groovy #!/usr/bin/env groovy
int timeout_minutes = 30
int delay_minutes = 5
int ci_timeout = (timeout_minutes - delay_minutes) * 60
pipeline { pipeline {
agent none agent none
options { options {
timestamps() timestamps()
timeout(time: 30, unit: 'MINUTES') timeout(time: timeout_minutes, unit: 'MINUTES')
buildDiscarder logRotator(artifactDaysToKeepStr: '30') buildDiscarder logRotator(artifactDaysToKeepStr: '30')
// parallelsAlwaysFailFast() // parallelsAlwaysFailFast()
...@@ -54,6 +58,7 @@ pipeline { ...@@ -54,6 +58,7 @@ pipeline {
if ("${MILVUS_CLIENT}" == "pymilvus") { if ("${MILVUS_CLIENT}" == "pymilvus") {
sh """ sh """
MILVUS_CLUSTER_ENABLED=${clusterEnabled} \ MILVUS_CLUSTER_ENABLED=${clusterEnabled} \
timeout ${ci_timeout} \
./e2e-k8s.sh \ ./e2e-k8s.sh \
--node-image registry.zilliz.com/kindest/node:v1.20.2 \ --node-image registry.zilliz.com/kindest/node:v1.20.2 \
--kind-config "${env.WORKSPACE}/build/config/topology/trustworthy-jwt-ci.yaml" \ --kind-config "${env.WORKSPACE}/build/config/topology/trustworthy-jwt-ci.yaml" \
...@@ -62,6 +67,7 @@ pipeline { ...@@ -62,6 +67,7 @@ pipeline {
} else if ("${MILVUS_CLIENT}" == "pymilvus-orm") { } else if ("${MILVUS_CLIENT}" == "pymilvus-orm") {
sh """ sh """
MILVUS_CLUSTER_ENABLED=${clusterEnabled} \ MILVUS_CLUSTER_ENABLED=${clusterEnabled} \
timeout ${ci_timeout} \
./e2e-k8s.sh \ ./e2e-k8s.sh \
--node-image registry.zilliz.com/kindest/node:v1.20.2 \ --node-image registry.zilliz.com/kindest/node:v1.20.2 \
--kind-config "${env.WORKSPACE}/build/config/topology/trustworthy-jwt-ci.yaml" \ --kind-config "${env.WORKSPACE}/build/config/topology/trustworthy-jwt-ci.yaml" \
......
...@@ -5,6 +5,10 @@ ...@@ -5,6 +5,10 @@
String cron_timezone = "TZ=Asia/Shanghai" String cron_timezone = "TZ=Asia/Shanghai"
String cron_string = BRANCH_NAME == "master" ? "50 22 * * * " : "" String cron_string = BRANCH_NAME == "master" ? "50 22 * * * " : ""
int timeout_minutes = 90
int delay_minutes = 5
int ci_timeout = (timeout_minutes - delay_minutes) * 60
pipeline { pipeline {
agent none agent none
triggers { triggers {
...@@ -13,7 +17,7 @@ pipeline { ...@@ -13,7 +17,7 @@ pipeline {
} }
options { options {
timestamps() timestamps()
timeout(time: 90, unit: 'MINUTES') timeout(time: timeout_minutes, unit: 'MINUTES')
buildDiscarder logRotator(artifactDaysToKeepStr: '30') buildDiscarder logRotator(artifactDaysToKeepStr: '30')
// parallelsAlwaysFailFast() // parallelsAlwaysFailFast()
} }
...@@ -62,6 +66,7 @@ pipeline { ...@@ -62,6 +66,7 @@ pipeline {
if ("${MILVUS_CLIENT}" == "pymilvus") { if ("${MILVUS_CLIENT}" == "pymilvus") {
sh """ sh """
MILVUS_CLUSTER_ENABLED=${clusterEnabled} \ MILVUS_CLUSTER_ENABLED=${clusterEnabled} \
timeout ${ci_timeout} \
./e2e-k8s.sh \ ./e2e-k8s.sh \
--kind-config "${env.WORKSPACE}/build/config/topology/trustworthy-jwt-ci.yaml" \ --kind-config "${env.WORKSPACE}/build/config/topology/trustworthy-jwt-ci.yaml" \
--node-image registry.zilliz.com/kindest/node:v1.20.2 --node-image registry.zilliz.com/kindest/node:v1.20.2
...@@ -69,6 +74,7 @@ pipeline { ...@@ -69,6 +74,7 @@ pipeline {
} else if ("${MILVUS_CLIENT}" == "pymilvus-orm") { } else if ("${MILVUS_CLIENT}" == "pymilvus-orm") {
sh """ sh """
MILVUS_CLUSTER_ENABLED=${clusterEnabled} \ MILVUS_CLUSTER_ENABLED=${clusterEnabled} \
timeout ${ci_timeout} \
./e2e-k8s.sh \ ./e2e-k8s.sh \
--kind-config "${env.WORKSPACE}/build/config/topology/trustworthy-jwt-ci.yaml" \ --kind-config "${env.WORKSPACE}/build/config/topology/trustworthy-jwt-ci.yaml" \
--node-image registry.zilliz.com/kindest/node:v1.20.2 \ --node-image registry.zilliz.com/kindest/node:v1.20.2 \
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册