Debian Codegraph @

mysql-test/suite/group_replication/r/gr_clone_applier_stop.result

raw
1 include/group_replication.inc
2 Warnings:
3 Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
4 Note #### Storing MySQL user name or password information in the connection metadata repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START REPLICA; see the 'START REPLICA Syntax' in the MySQL Manual for more information.
5 [connection server1]
6
7 # 1. Bootstrap M1 and install clone plugin.
8
9 include/start_and_bootstrap_group_replication.inc
10 INSTALL PLUGIN clone SONAME 'CLONE_PLUGIN';
11 CREATE TABLE t1 (a INT PRIMARY KEY);
12 INSERT INTO t1 values (1);
13 INSERT INTO t1 values (2);
14
15 # 2. Setup clone on M2.
16
17 [connection server2]
18 include/spawn_monitoring_process.inc
19 INSTALL PLUGIN clone SONAME 'CLONE_PLUGIN';
20
21 # 3. Force clone. Force applier failure on M2.
22 # Start GR on M2 fails. Applier fails before clone stops applier.
23 # Assert clone never starts.
24
25 [connection server2]
26 SET GLOBAL group_replication_clone_threshold= 1;
27 SET GLOBAL group_replication_group_name= "GROUP_NAME";
28 SET @@GLOBAL.DEBUG= '+d,force_sql_thread_error';
29 SET @@GLOBAL.DEBUG='+d,gr_clone_before_applier_stop';
30 START GROUP_REPLICATION;;
31 [connection server_2]
32 SET DEBUG_SYNC = 'now SIGNAL applier_stopped';
33 SET @@GLOBAL.DEBUG='-d,gr_clone_before_applier_stop';
34 [connection server2]
35 SET @@GLOBAL.DEBUG= '-d,force_sql_thread_error';
36 SET DEBUG_SYNC= 'RESET';
37 include/assert.inc [Clone must not start.]
38
39 # 4. Reset debug points for applier failures.
40 # Restart GR on M2.
41 # Assert clone starts and group_replication_applier SQL thread is OFF.
42
43 SET @@GLOBAL.DEBUG='+d,gr_clone_wait';
44 START GROUP_REPLICATION;
45 SET DEBUG_SYNC = 'now WAIT_FOR gr_clone_paused';
46 SET @@GLOBAL.DEBUG='-d,gr_clone_wait';
47 include/assert.inc [group_replication_applier SQL Thread will be off.]
48 SET DEBUG_SYNC = 'now SIGNAL gr_clone_continue';
49 include/rpl_reconnect.inc
50 include/gr_wait_for_member_state.inc
51 include/assert.inc [Clone must be completed]
52
53 # 5. Block applier on M2.
54 # Uninstall clone on M1 so that clone fails.
55 # Create some transactions on M1 to create applier backlog on M2.
56
57 SET @@GLOBAL.DEBUG='+d,block_applier_updates';
58 [connection server1]
59 UNINSTALL PLUGIN clone;
60 INSERT INTO t1 values (3);
61 INSERT INTO t1 values (4);
62 [connection server2]
63
64 # 6. Stop GR on M2 without committing the received transactions.
65 # Create transactions on M1 for M2 to clone.
66
67 SET DEBUG_SYNC = "now WAIT_FOR applier_read_blocked";
68 SET @@GLOBAL.DEBUG='-d,block_applier_updates';
69 SET @@GLOBAL.DEBUG='+d,force_sql_thread_error';
70 SET DEBUG_SYNC = "now SIGNAL resume_applier_read";
71 include/gr_wait_for_member_state.inc
72 SET @@GLOBAL.DEBUG='-d,force_sql_thread_error';
73 include/stop_group_replication.inc
74 [connection server1]
75 INSERT INTO t1 values (5);
76 INSERT INTO t1 values (6);
77
78 # 7. Start GR on M2.
79 # Clone will fail and incremental recovery will start.
80 # Applier will be OFF till clone failure is detected.
81
82 [connection server1]
83 SET @@GLOBAL.DEBUG='+d,block_applier_updates';
84 [connection server2]
85 SET @@GLOBAL.DEBUG='+d,gr_run_clone_query_fail_once';
86 SET GLOBAL group_replication_clone_threshold= 1;
87 START GROUP_REPLICATION;
88 SET DEBUG_SYNC = 'now WAIT_FOR signal.run_clone_query_waiting';
89 SET @@GLOBAL.DEBUG='-d,gr_run_clone_query_fail_once';
90 include/assert.inc ["Clone is executing"]
91 include/assert.inc [group_replication_applier SQL Thread will be OFF.]
92 SET DEBUG_SYNC = 'now SIGNAL signal.run_clone_query_continue';
93 include/assert.inc [group_replication_applier SQL Thread will be ON.]
94 [connection server1]
95 SET DEBUG_SYNC = "now WAIT_FOR applier_read_blocked";
96 SET @@GLOBAL.DEBUG='-d,block_applier_updates';
97 SET DEBUG_SYNC = "now SIGNAL resume_applier_read";
98 [connection server2]
99 include/gr_wait_for_member_state.inc
100 include/diff_tables.inc [server1:test.t1, server2:test.t1]
101
102 # 8. Cleanup.
103
104 [connection server1]
105 DROP TABLE t1;
106 set session sql_log_bin=0;
107 call mtr.add_suppression("Timeout while waiting for the group communication engine to exit!");
108 call mtr.add_suppression("The member has failed to gracefully leave the group.");
109 set session sql_log_bin=1;
110 [connection server2]
111 set session sql_log_bin=0;
112 call mtr.add_suppression("Replica SQL for channel 'group_replication_applier': Relay log read failure: *.*");
113 call mtr.add_suppression("The applier thread execution was aborted. *.*");
114 call mtr.add_suppression("Error running query, replica SQL thread aborted. *");
115 call mtr.add_suppression("Fatal error during execution on the Applier process of Group Replication. The server will now leave the group.");
116 call mtr.add_suppression("Skipping leave operation: concurrent attempt to leave the group is on-going.");
117 call mtr.add_suppression("Unable to confirm whether the server has left the group or not. Check performance_schema.replication_group_members to check group membership information.");
118 call mtr.add_suppression("The server was automatically set into read only mode after an error was detected.");
119 call mtr.add_suppression("Unable to initialize the Group Replication applier module.");
120 call mtr.add_suppression("There was a previous plugin error while the member joined the group. The member will now exit the group.");
121 call mtr.add_suppression("This member will start distributed recovery using clone. It is due to the number of missing transactions being higher than the configured threshold of 1.");
122 call mtr.add_suppression("Clone removing all user data for provisioning: *");
123 call mtr.add_suppression("Internal query: CLONE INSTANCE FROM *");
124 call mtr.add_suppression("There was an issue when cloning from another server: *");
125 call mtr.add_suppression("Due to some issue on the previous step distributed recovery is now executing: Incremental Recovery.");
126 call mtr.add_suppression("Timeout while waiting for the group communication engine to be ready!");
127 call mtr.add_suppression("The group communication engine is not ready for the member to join. .*");
128 call mtr.add_suppression("The member was unable to join the group.*");
129 call mtr.add_suppression("There was an issue when configuring the remote cloning process: The plugin was not able to stop the group_replication_applier channel.");
130 set session sql_log_bin=1;
131 RESET PERSIST group_replication_group_name;
132 RESET PERSIST group_replication_local_address;
133 RESET PERSIST group_replication_group_seeds;
134 RESET PERSIST group_replication_start_on_boot;
135 RESET PERSIST IF EXISTS group_replication_communication_stack;
136 include/clean_monitoring_process.inc
137 include/group_replication_end.inc