@@ -41,10 +41,10 @@ run_br --pd $PD_ADDR backup table -s "local://$TEST_DIR/$DB/full" --db $DB -t $T
4141
4242# when we backup, we should close domain in one shot session.
4343# so we can check the log count of `one shot domain closed` to be 2.
44- # we will call UseOneShotSession twice to get the value global variable.
44+ # we will call UseOneShotSession once to get the value global variable.
4545one_shot_session_count=$( cat $LOG | grep " one shot session closed" | wc -l | xargs)
4646one_shot_domain_count=$( cat $LOG | grep " one shot domain closed" | wc -l | xargs)
47- if [ " ${one_shot_session_count} " -ne " 2 " ] || [ " $one_shot_domain_count " -ne " 2 " ]; then
47+ if [ " ${one_shot_session_count} " -ne " 1 " ] || [ " $one_shot_domain_count " -ne " 1 " ]; then
4848 echo " TEST: [$TEST_NAME ] fail on one shot session check during backup, $one_shot_session_count , $one_shot_domain_count "
4949 exit 1
5050fi
@@ -74,13 +74,13 @@ last_backup_ts=$(run_br validate decode --field="end-version" -s "local://$TEST_
7474run_br --pd $PD_ADDR backup db -s " local://$TEST_DIR /$DB /inc" --db $DB --lastbackupts $last_backup_ts --log-file $LOG
7575
7676# when we doing incremental backup, we should close domain in one shot session.
77- # so we can check the log count of `one shot domain closed` to be 3 .
78- # we will call UseOneShotSession three times
79- # 1. to get the value global variable twice .
77+ # so we can check the log count of `one shot domain closed` to be 2 .
78+ # we will call UseOneShotSession two times
79+ # 1. to get the value global variable once .
8080# 2. to get all ddl jobs with session.
8181one_shot_session_count=$( cat $LOG | grep " one shot session closed" | wc -l | xargs)
8282one_shot_domain_count=$( cat $LOG | grep " one shot domain closed" | wc -l | xargs)
83- if [ " ${one_shot_session_count} " -ne " 3 " ] || [ " $one_shot_domain_count " -ne " 3 " ]; then
83+ if [ " ${one_shot_session_count} " -ne " 2 " ] || [ " $one_shot_domain_count " -ne " 2 " ]; then
8484 echo " TEST: [$TEST_NAME ] fail on one shot session check during inc backup, $one_shot_session_count , $one_shot_domain_count "
8585 exit 1
8686fi
0 commit comments