From e4ef431b0f31ae5caf94ea270bfaa0a9dfae6552 Mon Sep 17 00:00:00 2001 From: Graham Whaley Date: Tue, 13 Aug 2019 16:46:53 +0100 Subject: [PATCH] metrics: parallel scaling: add 'grace' handling When 'grace' handling was added, it got missed from the parallel script (which shares the bb.*.in files). Add it in to fix the test. Signed-off-by: Graham Whaley --- metrics/scaling/k8s_parallel.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/metrics/scaling/k8s_parallel.sh b/metrics/scaling/k8s_parallel.sh index 23312c5..15bb36a 100755 --- a/metrics/scaling/k8s_parallel.sh +++ b/metrics/scaling/k8s_parallel.sh @@ -29,6 +29,7 @@ LABELVALUE=${LABELVALUE:-parallel} wait_time=${wait_time:-30} delete_wait_time=${delete_wait_time:-600} use_api=${use_api:-yes} +grace=${grace:-30} # Set some default metrics env vars TEST_ARGS="runtime=${RUNTIME}" @@ -78,6 +79,7 @@ warmup() { -e "s|@DEPLOYMENT@|${deployment}|g" \ -e "s|@LABEL@|${LABEL}|g" \ -e "s|@LABELVALUE@|${LABELVALUE}|g" \ + -e "s|@GRACE@|${grace}|g" \ < ${input_yaml} > ${generated_yaml} info "Applying warmup pod" @@ -191,6 +193,7 @@ run() { -e "s|@DEPLOYMENT@|${deployment}|g" \ -e "s|@LABEL@|${LABEL}|g" \ -e "s|@LABELVALUE@|${LABELVALUE}|g" \ + -e "s|@GRACE@|${grace}|g" \ < ${input_template} > ${generated_file} info "Applying changes" @@ -248,6 +251,8 @@ show_vars() echo -e "\t\tSeconds to wait after pods ready before taking measurements" echo -e "\tuse_api (${use_api})" echo -e "\t\tspecify yes or no to use the API to launch pods" + echo -e "\tgrace (${grace})" + echo -e "\t\tspecify the grace period in seconds for workload pod termination" } help()