diff --git a/tools/internal_ci/linux/grpc_e2e_performance_gke.sh b/tools/internal_ci/linux/grpc_e2e_performance_gke.sh index 982caf79f7446..ba64a533c5437 100755 --- a/tools/internal_ci/linux/grpc_e2e_performance_gke.sh +++ b/tools/internal_ci/linux/grpc_e2e_performance_gke.sh @@ -120,6 +120,24 @@ buildConfigs() { -o "loadtest_with_prebuilt_workers_${pool}.yaml" } +# Regex to disable specific tests. +# https://stackoverflow.com/questions/406230 +disableTestsRegex() { + if (($# == 0)); then + echo '.*' + return + fi + local s='^((?!'+"$1" + shift + while (($# > 0)); do + s+='|' + s+="$1" + shift + done + s+=').)*$' + echo "${s}" +} + # List all languages. declare -A useLanguage=( [c++]=1 @@ -190,8 +208,18 @@ if [[ -v "useLanguage[ruby]" ]]; then runnerLangArgs+=(-l "ruby:${GRPC_CORE_REPO}:${GRPC_CORE_COMMIT}") fi -buildConfigs "${WORKER_POOL_8CORE}" "${BIGQUERY_TABLE_8CORE}" "${configLangArgs8core[@]}" -buildConfigs "${WORKER_POOL_32CORE}" "${BIGQUERY_TABLE_32CORE}" "${configLangArgs32core[@]}" +# Disable broken tests by regex. +declare -a disabledTests8core=( + cpp_protobuf_async_client_unary_1channel_64wide_128breq_8mbresp_insecure +) +declare -a disabledTests32core=() + +# Arguments to disable tests. +regexArgs8core=(-r "$(disabledTestsRegex "${disabledTests8core[@]}")") +regexArgs32core=(-r "$(disabledTestsRegex "${disabledTests32core[@]}")") + +buildConfigs "${WORKER_POOL_8CORE}" "${BIGQUERY_TABLE_8CORE}" "${configLangArgs8core[@]}" "${regexArgs8core[@]}" +buildConfigs "${WORKER_POOL_32CORE}" "${BIGQUERY_TABLE_32CORE}" "${configLangArgs32core[@]}" "${regexArgs32core[@]}" # Delete prebuilt images on exit. deleteImages() { diff --git a/tools/internal_ci/linux/grpc_e2e_performance_gke_experiment.sh b/tools/internal_ci/linux/grpc_e2e_performance_gke_experiment.sh index e265233fa388b..7ad284154ecbb 100755 --- a/tools/internal_ci/linux/grpc_e2e_performance_gke_experiment.sh +++ b/tools/internal_ci/linux/grpc_e2e_performance_gke_experiment.sh @@ -115,6 +115,24 @@ buildConfigs() { -o "loadtest_with_prebuilt_workers_${pool}.yaml" } +# Regex to disable specific tests. +# https://stackoverflow.com/questions/406230 +disableTestsRegex() { + if (($# == 0)); then + echo '.*' + return + fi + local s='^((?!'+"$1" + shift + while (($# > 0)); do + s+='|' + s+="$1" + shift + done + s+=').)*$' + echo "${s}" +} + # List all languages. declare -A useLanguage=( [c++]=1 @@ -185,8 +203,18 @@ if [[ -v "useLanguage[ruby]" ]]; then runnerLangArgs+=(-l "ruby:${GRPC_CORE_REPO}:${GRPC_CORE_COMMIT}") fi -buildConfigs "${WORKER_POOL_8CORE}" "${BIGQUERY_TABLE_8CORE}" "${configLangArgs8core[@]}" -buildConfigs "${WORKER_POOL_32CORE}" "${BIGQUERY_TABLE_32CORE}" "${configLangArgs32core[@]}" +# Disable broken tests by regex. +declare -a disabledTests8core=( + cpp_protobuf_async_client_unary_1channel_64wide_128breq_8mbresp_insecure +) +declare -a disabledTests32core=() + +# Arguments to disable tests. +regexArgs8core=(-r "$(disabledTestsRegex "${disabledTests8core[@]}")") +regexArgs32core=(-r "$(disabledTestsRegex "${disabledTests32core[@]}")") + +buildConfigs "${WORKER_POOL_8CORE}" "${BIGQUERY_TABLE_8CORE}" "${configLangArgs8core[@]}" "${regexArgs8core[@]}" +buildConfigs "${WORKER_POOL_32CORE}" "${BIGQUERY_TABLE_32CORE}" "${configLangArgs32core[@]}" "${regexArgs32core[@]}" # Delete prebuilt images on exit. deleteImages() {