From ddf245c0b67ae833de012472a4d285515199df9e Mon Sep 17 00:00:00 2001 From: Bugen Zhao Date: Mon, 6 May 2024 15:46:37 +0800 Subject: [PATCH] no need to kill kafka or zookeeper Signed-off-by: Bugen Zhao --- backwards-compat-tests/scripts/utils.sh | 38 ------------------------- 1 file changed, 38 deletions(-) diff --git a/backwards-compat-tests/scripts/utils.sh b/backwards-compat-tests/scripts/utils.sh index b0100678800de..5c465151c9168 100644 --- a/backwards-compat-tests/scripts/utils.sh +++ b/backwards-compat-tests/scripts/utils.sh @@ -23,32 +23,6 @@ KAFKA_PATH=.risingwave/bin/kafka mkdir -p $TEST_DIR cp -r backwards-compat-tests/slt/* $TEST_DIR -wait_kafka_exit() { - # Follow kafka-server-stop.sh - while [[ -n "$(ps ax | grep ' kafka\.Kafka ' | grep java | grep -v grep | awk '{print $1}')" ]]; do - echo "Waiting for kafka to exit" - sleep 1 - done -} - -wait_zookeeper_exit() { - # Follow zookeeper-server-stop.sh - while [[ -n "$(ps ax | grep java | grep -i QuorumPeerMain | grep -v grep | awk '{print $1}')" ]]; do - echo "Waiting for zookeeper to exit" - sleep 1 - done -} - -kill_kafka() { - $KAFKA_PATH/bin/kafka-server-stop.sh - wait_kafka_exit -} - -kill_zookeeper() { - $KAFKA_PATH/bin/zookeeper-server-stop.sh - wait_zookeeper_exit -} - wait_for_process() { process_name="$1" @@ -77,21 +51,9 @@ kill_cluster() { # Kill other components $TMUX list-windows -t risedev -F "#{window_name} #{pane_id}" | - grep -v 'kafka' | - grep -v 'zookeeper' | awk '{ print $2 }' | xargs -I {} $TMUX send-keys -t {} C-c C-d - set +e - if [[ -n $($TMUX list-windows -t risedev | grep kafka) ]]; then - echo "kill kafka" - kill_kafka - - echo "kill zookeeper" - kill_zookeeper - fi - set -e - $TMUX kill-server test $? -eq 0 || { echo "Failed to stop all RiseDev components."