From e5f5d5e08a7698b0f02849f18ac211e785ecb553 Mon Sep 17 00:00:00 2001 From: zhuwenxing Date: Thu, 2 Jun 2022 14:34:07 +0800 Subject: [PATCH] [skip e2e]Update config for deploy and chaos test (#17333) Signed-off-by: zhuwenxing --- build/ci/jenkins/ChaosTest.groovy | 17 +++------- build/ci/jenkins/ChaosTestKafkaMQ.groovy | 34 ++++++++++++++----- build/ci/jenkins/DeployTest.groovy | 20 ++++++----- build/ci/jenkins/DeployTestKafkaMQ.groovy | 15 ++++++++ tests/python_client/chaos/cluster-values.yaml | 4 +-- .../chaos/standalone-values.yaml | 4 +-- .../python_client/deploy/cluster-values.yaml | 4 +-- .../deploy/standalone-values.yaml | 4 +-- 8 files changed, 65 insertions(+), 37 deletions(-) diff --git a/build/ci/jenkins/ChaosTest.groovy b/build/ci/jenkins/ChaosTest.groovy index a91517c9bf..cc85f3b2ef 100644 --- a/build/ci/jenkins/ChaosTest.groovy +++ b/build/ci/jenkins/ChaosTest.groovy @@ -44,23 +44,18 @@ pipeline { string( description: 'Etcd Image Repository', name: 'etcd_image_repository', - defaultValue: "milvusdb/etcd" + defaultValue: "bitnami/etcd" ) string( description: 'Etcd Image Tag', name: 'etcd_image_tag', - defaultValue: "3.5.0-debian-10-r117" + defaultValue: "3.5.0-debian-10-r24" ) string( description: 'Query Replic Nums', - name: 'querynode_replica_nums', + name: 'querynode_nums', defaultValue: '3' ) - string( - description: 'Pod Nums', - name: 'pod_nums', - defaultValue: '1' - ) booleanParam( description: 'Keep Env', name: 'keep_env', @@ -92,12 +87,11 @@ pipeline { dir ('tests/python_client/chaos') { script { sh """ - yq -i '.queryNode.replicas = "${params.querynode_replica_nums}"' cluster-values.yaml + yq -i '.queryNode.replicas = "${params.querynode_nums}"' cluster-values.yaml yq -i '.etcd.image.repository = "${params.etcd_image_repository}"' cluster-values.yaml yq -i '.etcd.image.tag = "${params.etcd_image_tag}"' cluster-values.yaml yq -i '.etcd.image.repository = "${params.etcd_image_repository}"' standalone-values.yaml yq -i '.etcd.image.tag = "${params.etcd_image_tag}"' standalone-values.yaml - cat cluster-values.yaml """ } } @@ -106,7 +100,7 @@ pipeline { } stage ('Deploy Milvus') { options { - timeout(time: 10, unit: 'MINUTES') // timeout on this stage + timeout(time: 15, unit: 'MINUTES') // timeout on this stage } steps { container('main') { @@ -121,7 +115,6 @@ pipeline { } sh "echo ${image_tag_modified}" sh "echo ${params.chaos_type}" - sh "docker pull ${params.image_repository}:${image_tag_modified}" sh "helm repo add milvus https://milvus-io.github.io/milvus-helm" sh "helm repo update" if ("${params.pod_name}" == "standalone"){ diff --git a/build/ci/jenkins/ChaosTestKafkaMQ.groovy b/build/ci/jenkins/ChaosTestKafkaMQ.groovy index 7e96d49e57..3abdfe114d 100644 --- a/build/ci/jenkins/ChaosTestKafkaMQ.groovy +++ b/build/ci/jenkins/ChaosTestKafkaMQ.groovy @@ -42,9 +42,19 @@ pipeline { defaultValue: 'master-latest' ) string( - description: 'Pod Nums', - name: 'pod_nums', - defaultValue: '1' + description: 'Etcd Image Repository', + name: 'etcd_image_repository', + defaultValue: "bitnami/etcd" + ) + string( + description: 'Etcd Image Tag', + name: 'etcd_image_tag', + defaultValue: "3.5.0-debian-10-r24" + ) + string( + description: 'Query Replic Nums', + name: 'querynode_nums', + defaultValue: '3' ) booleanParam( description: 'Keep Env', @@ -76,17 +86,24 @@ pipeline { container('main') { dir ('tests/python_client/chaos') { script { - sh "yq -i '.kafka.enabled = true' cluster-values.yaml" - sh "yq -i '.pulsar.enabled = false' cluster-values.yaml" - sh "cat cluster-values.yaml" + sh""" + yq -i '.kafka.enabled = true' cluster-values.yaml + yq -i '.pulsar.enabled = false' cluster-values.yaml + + yq -i '.queryNode.replicas = "${params.querynode_nums}"' cluster-values.yaml + yq -i '.etcd.image.repository = "${params.etcd_image_repository}"' cluster-values.yaml + yq -i '.etcd.image.tag = "${params.etcd_image_tag}"' cluster-values.yaml + yq -i '.etcd.image.repository = "${params.etcd_image_repository}"' standalone-values.yaml + yq -i '.etcd.image.tag = "${params.etcd_image_tag}"' standalone-values.yaml + """ } } } - } + } } stage ('Deploy Milvus') { options { - timeout(time: 10, unit: 'MINUTES') // timeout on this stage + timeout(time: 15, unit: 'MINUTES') // timeout on this stage } steps { container('main') { @@ -101,7 +118,6 @@ pipeline { } sh "echo ${image_tag_modified}" sh "echo ${params.chaos_type}" - sh "docker pull ${params.image_repository}:${image_tag_modified}" sh "helm repo add milvus https://milvus-io.github.io/milvus-helm" sh "helm repo update" if ("${params.pod_name}" == "standalone"){ diff --git a/build/ci/jenkins/DeployTest.groovy b/build/ci/jenkins/DeployTest.groovy index b45a845c96..f4b2a5901d 100644 --- a/build/ci/jenkins/DeployTest.groovy +++ b/build/ci/jenkins/DeployTest.groovy @@ -51,16 +51,16 @@ pipeline { string( description: 'Etcd Image Repository', name: 'etcd_image_repository', - defaultValue: "milvusdb/etcd" + defaultValue: "bitnami/etcd" ) string( description: 'Etcd Image Tag', name: 'etcd_image_tag', - defaultValue: "3.5.0-debian-10-r117" + defaultValue: "3.5.0-debian-10-r24" ) string( - description: 'Query Replic Nums', - name: 'querynode_replica_nums', + description: 'Querynode Nums', + name: 'querynode_nums', defaultValue: '3' ) string( @@ -105,7 +105,7 @@ pipeline { dir ('tests/python_client/deploy') { script { sh """ - yq -i '.queryNode.replicas = "${params.querynode_replica_nums}"' cluster-values.yaml + yq -i '.queryNode.replicas = "${params.querynode_nums}"' cluster-values.yaml yq -i '.etcd.image.repository = "${params.etcd_image_repository}"' cluster-values.yaml yq -i '.etcd.image.tag = "${params.etcd_image_tag}"' cluster-values.yaml yq -i '.etcd.image.repository = "${params.etcd_image_repository}"' standalone-values.yaml @@ -119,7 +119,7 @@ pipeline { } stage ('First Milvus Deployment') { options { - timeout(time: 10, unit: 'MINUTES') // timeout on this stage + timeout(time: 15, unit: 'MINUTES') // timeout on this stage } steps { container('main') { @@ -152,8 +152,6 @@ pipeline { sh "echo ${new_image_tag_modified} > new_image_tag_modified.txt" stash includes: 'new_image_tag_modified.txt', name: 'new_image_tag_modified' env.new_image_tag_modified = new_image_tag_modified - sh "docker pull ${params.old_image_repository}:${old_image_tag_modified}" - sh "docker pull ${params.new_image_repository}:${new_image_tag_modified}" if ("${params.deploy_task}" == "reinstall"){ echo "reinstall Milvus with new image tag" old_image_tag_modified = new_image_tag_modified @@ -183,6 +181,9 @@ pipeline { } } stage ('Run first test') { + options { + timeout(time: 30, unit: 'MINUTES') // timeout on this stage + } steps { container('main') { dir ('tests/python_client/deploy/scripts') { @@ -275,6 +276,9 @@ pipeline { } stage ('Run Second Test') { + options { + timeout(time: 30, unit: 'MINUTES') // timeout on this stage + } steps { container('main') { dir ('tests/python_client/deploy/scripts') { diff --git a/build/ci/jenkins/DeployTestKafkaMQ.groovy b/build/ci/jenkins/DeployTestKafkaMQ.groovy index de10cf0f9d..601d367622 100644 --- a/build/ci/jenkins/DeployTestKafkaMQ.groovy +++ b/build/ci/jenkins/DeployTestKafkaMQ.groovy @@ -48,6 +48,21 @@ pipeline { name: 'new_image_tag', defaultValue: 'master-latest' ) + string( + description: 'Etcd Image Repository', + name: 'etcd_image_repository', + defaultValue: "bitnami/etcd" + ) + string( + description: 'Etcd Image Tag', + name: 'etcd_image_tag', + defaultValue: "3.5.0-debian-10-r24" + ) + string( + description: 'Querynode Nums', + name: 'querynode_nums', + defaultValue: '3' + ) string( description: 'Data Size', name: 'data_size', diff --git a/tests/python_client/chaos/cluster-values.yaml b/tests/python_client/chaos/cluster-values.yaml index 30dbed151b..dd1f5837c3 100644 --- a/tests/python_client/chaos/cluster-values.yaml +++ b/tests/python_client/chaos/cluster-values.yaml @@ -9,8 +9,8 @@ image: etcd: replicaCount: 3 image: - repository: milvusdb/etcd - tag: 3.5.0-debian-10-r117 + repository: bitnami/etcd + tag: 3.5.0-debian-10-r24 minio: resources: diff --git a/tests/python_client/chaos/standalone-values.yaml b/tests/python_client/chaos/standalone-values.yaml index 42592e5a4d..1282062dae 100644 --- a/tests/python_client/chaos/standalone-values.yaml +++ b/tests/python_client/chaos/standalone-values.yaml @@ -8,8 +8,8 @@ image: etcd: replicaCount: 1 image: - repository: milvusdb/etcd - tag: 3.5.0-debian-10-r117 + repository: bitnami/etcd + tag: 3.5.0-debian-10-r24 minio: mode: standalone pulsar: diff --git a/tests/python_client/deploy/cluster-values.yaml b/tests/python_client/deploy/cluster-values.yaml index 48877f1176..d3faf746bb 100644 --- a/tests/python_client/deploy/cluster-values.yaml +++ b/tests/python_client/deploy/cluster-values.yaml @@ -9,8 +9,8 @@ image: etcd: replicaCount: 3 image: - repository: milvusdb/etcd - tag: 3.5.0-debian-10-r117 + repository: bitnami/etcd + tag: 3.5.0-debian-10-r24 minio: resources: diff --git a/tests/python_client/deploy/standalone-values.yaml b/tests/python_client/deploy/standalone-values.yaml index eac8ba7404..229ac1417b 100644 --- a/tests/python_client/deploy/standalone-values.yaml +++ b/tests/python_client/deploy/standalone-values.yaml @@ -8,8 +8,8 @@ image: etcd: replicaCount: 1 image: - repository: milvusdb/etcd - tag: 3.5.0-debian-10-r117 + repository: bitnami/etcd + tag: 3.5.0-debian-10-r24 minio: mode: standalone pulsar: