Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "dm/test: swap upstream and downstream of sync_diff in some ca… (#4382) #4398

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 0 additions & 31 deletions dm/tests/adjust_gtid/conf/diff_config_revert_1.toml

This file was deleted.

31 changes: 0 additions & 31 deletions dm/tests/adjust_gtid/conf/diff_config_revert_2.toml

This file was deleted.

6 changes: 2 additions & 4 deletions dm/tests/adjust_gtid/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,7 @@ function run() {
"start-task $WORK_DIR/dm-task.yaml --remove-meta"

# use sync_diff_inspector to check full dump loader
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_1.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_2.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config.toml

name1=$(grep "Log: " $WORK_DIR/worker1/dumped_data.$TASK_NAME/metadata | awk -F: '{print $2}' | tr -d ' ')
pos1=$(grep "Pos: " $WORK_DIR/worker1/dumped_data.$TASK_NAME/metadata | awk -F: '{print $2}' | tr -d ' ')
Expand Down Expand Up @@ -132,8 +131,7 @@ function run() {
check_rpc_alive $cur/../bin/check_worker_online 127.0.0.1:$WORKER2_PORT

# use sync_diff_inspector to check incremental dump loader
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_1.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_2.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config.toml

run_sql_both_source "SET @@GLOBAL.SQL_MODE='ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION'"
run_sql_both_source "SET @@global.time_zone = 'SYSTEM';"
Expand Down
30 changes: 0 additions & 30 deletions dm/tests/full_mode/conf/diff_config_revert_1.toml

This file was deleted.

30 changes: 0 additions & 30 deletions dm/tests/full_mode/conf/diff_config_revert_2.toml

This file was deleted.

10 changes: 3 additions & 7 deletions dm/tests/full_mode/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ function fail_acquire_global_lock() {
"you need (at least one of) the RELOAD privilege(s) for this operation" 2

cleanup_data full_mode
cleanup_data_upstream full_mode
cleanup_process $*
}

Expand Down Expand Up @@ -105,6 +104,7 @@ function escape_schema() {

# start DM task only
dmctl_start_task "$WORK_DIR/dm-task.yaml" "--remove-meta"
check_sync_diff $WORK_DIR $WORK_DIR/diff_config.toml

check_log_contain_with_retry 'clean dump files' $WORK_DIR/worker1/log/dm-worker.log
check_log_contain_with_retry 'clean dump files' $WORK_DIR/worker2/log/dm-worker.log
Expand All @@ -118,7 +118,6 @@ function escape_schema() {
check_metric $WORKER2_PORT 'dumpling_dump_finished_tables' 3 0 3

cleanup_data full/mode
cleanup_data_upstream full/mode
cleanup_process $*
}

Expand All @@ -131,8 +130,7 @@ function empty_data() {
init_cluster

dmctl_start_task "$cur/conf/dm-task.yaml" "--remove-meta"
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_1.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_2.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config.toml

run_dm_ctl $WORK_DIR "127.0.0.1:$MASTER_PORT" \
"query-status test" \
Expand All @@ -144,7 +142,6 @@ function empty_data() {
check_log_contains $WORK_DIR/worker2/log/dm-worker.log "progress=\"100.00 %\""

cleanup_data full_mode
cleanup_data_upstream full_mode
cleanup_process $*
}

Expand Down Expand Up @@ -193,8 +190,7 @@ function run() {
dmctl_start_task "$cur/conf/dm-task.yaml" "--remove-meta"

# use sync_diff_inspector to check full dump loader
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_1.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_2.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config.toml

echo "check dump files have been cleaned"
ls $WORK_DIR/worker1/dumped_data.test && exit 1 || echo "worker1 auto removed dump files"
Expand Down
30 changes: 0 additions & 30 deletions dm/tests/incremental_mode/conf/diff_config_revert_1.toml

This file was deleted.

30 changes: 0 additions & 30 deletions dm/tests/incremental_mode/conf/diff_config_revert_2.toml

This file was deleted.

6 changes: 2 additions & 4 deletions dm/tests/incremental_mode/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,7 @@ function run() {
sed -i "s/binlog-pos-placeholder-2/4/g" $WORK_DIR/dm-task.yaml
dmctl_start_task $WORK_DIR/dm-task.yaml

check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_1.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_2.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config.toml

dmctl_stop_task $TASK_NAME

Expand Down Expand Up @@ -266,8 +265,7 @@ function run() {
"resume-task test" \
"\"result\": true" 3

check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_1.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config_revert_2.toml
check_sync_diff $WORK_DIR $cur/conf/diff_config.toml

# test rotate binlog, after rotate and ddl, master binlog should be equal to sync binlog
run_sql "flush logs;" $MYSQL_PORT1 $MYSQL_PASSWORD1
Expand Down