From 03c6f911f903006bf116f75a2b0c4fd632f61bcf Mon Sep 17 00:00:00 2001 From: Leavrth Date: Fri, 26 Jan 2024 10:35:57 +0800 Subject: [PATCH 1/2] fix integration test Signed-off-by: Leavrth --- br/tests/br_check_new_collocation_enable/run.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/br/tests/br_check_new_collocation_enable/run.sh b/br/tests/br_check_new_collocation_enable/run.sh index d3ed9ad87cc24..6d5bc2b5fbee6 100755 --- a/br/tests/br_check_new_collocation_enable/run.sh +++ b/br/tests/br_check_new_collocation_enable/run.sh @@ -54,7 +54,7 @@ bin/brv4.0.8 backup db --db "$DB" -s "local://$TEST_DIR/$DB" \ # restore db from v4.0.8 version without `newCollationEnable` echo "restore start ... without NewCollactionEnable in backupmeta" restore_fail=0 -error_str="the config 'new_collations_enabled_on_first_bootstrap' not found in backupmeta" +error_str="the value 'new_collations_enabled_on_first_bootstrap' not found in backupmeta" test_log="new_collotion_enable_test.log" unset BR_LOG_TO_TERM run_br restore db --db $DB -s "local://$TEST_DIR/$DB" --pd $PD_ADDR --log-file $test_log || restore_fail=1 From 7f2f4c8f3cc0f854773b78287def2c239ddf7310 Mon Sep 17 00:00:00 2001 From: Leavrth Date: Fri, 26 Jan 2024 10:59:22 +0800 Subject: [PATCH 2/2] fix integration test Signed-off-by: Leavrth --- br/pkg/restore/client.go | 4 ++-- br/tests/br_check_new_collocation_enable/run.sh | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/br/pkg/restore/client.go b/br/pkg/restore/client.go index 1e3cfa1310048..7720ab332deee 100644 --- a/br/pkg/restore/client.go +++ b/br/pkg/restore/client.go @@ -3764,12 +3764,12 @@ func CheckNewCollationEnable( if backupNewCollationEnable == "" { if CheckRequirements { return enabled, errors.Annotatef(berrors.ErrUnknown, - "the value 'new_collations_enabled_on_first_bootstrap' not found in backupmeta. "+ + "the config 'new_collations_enabled_on_first_bootstrap' not found in backupmeta. "+ "you can use \"SELECT VARIABLE_VALUE FROM mysql.tidb WHERE VARIABLE_NAME='new_collations_enabled_on_first_bootstrap';\" to manually check the config. "+ "if you ensure the value 'new_collations_enabled_on_first_bootstrap' in backup cluster is as same as restore cluster, use --check-requirements=false to skip this check", ) } - log.Warn("the config 'new_collations_enabled_on_first_bootstrap' is not in backupmeta") + log.Warn("the config 'new_collations_enabled_on_first_bootstrap' is not found in backupmeta") return enabled, nil } diff --git a/br/tests/br_check_new_collocation_enable/run.sh b/br/tests/br_check_new_collocation_enable/run.sh index 6d5bc2b5fbee6..d3ed9ad87cc24 100755 --- a/br/tests/br_check_new_collocation_enable/run.sh +++ b/br/tests/br_check_new_collocation_enable/run.sh @@ -54,7 +54,7 @@ bin/brv4.0.8 backup db --db "$DB" -s "local://$TEST_DIR/$DB" \ # restore db from v4.0.8 version without `newCollationEnable` echo "restore start ... without NewCollactionEnable in backupmeta" restore_fail=0 -error_str="the value 'new_collations_enabled_on_first_bootstrap' not found in backupmeta" +error_str="the config 'new_collations_enabled_on_first_bootstrap' not found in backupmeta" test_log="new_collotion_enable_test.log" unset BR_LOG_TO_TERM run_br restore db --db $DB -s "local://$TEST_DIR/$DB" --pd $PD_ADDR --log-file $test_log || restore_fail=1