| 1 |
################### |
| 2 |
Cleanup and server setup |
| 3 |
################### |
| 4 |
# restart:--group_replication_local_address=GROUP_REPLICATION_LOCAL_ADDRESS --group_replication_group_seeds=GROUP_REPLICATION_GROUP_SEEDS |
| 5 |
server2 |
| 6 |
RESET MASTER; |
| 7 |
server1 |
| 8 |
RESET MASTER; |
| 9 |
server1 |
| 10 |
SET GLOBAL group_replication_group_name= "8a84f397-aaa4-18df-89ab-c70aa9823561"; |
| 11 |
################### |
| 12 |
Test start values |
| 13 |
################### |
| 14 |
include/assert.inc [The value of member_id should be empty before starting group replication] |
| 15 |
include/assert.inc [The value of view_id should be EMPTY before starting group replication] |
| 16 |
include/assert.inc [The value of Count_Transactions_in_queue should be 0 before starting group replication] |
| 17 |
include/assert.inc [The value of Count_Transactions_checked should be 0 before starting group replication] |
| 18 |
include/assert.inc [The value of Count_conflicts_detected should be 0 before starting group replication] |
| 19 |
include/assert.inc [The value of Count_Transactions_rows_validating should be 0 before starting group replication] |
| 20 |
include/assert.inc [The value of Transactions_Committed_all_members should be empty before starting group replication] |
| 21 |
include/assert.inc [The value of Last_conflict_free_transaction should be 0 before starting group replication] |
| 22 |
######################################################## |
| 23 |
Values being updated after executing some transactions |
| 24 |
######################################################## |
| 25 |
include/start_and_bootstrap_group_replication.inc |
| 26 |
include/assert.inc [The value of view_id should be a number followed by ONE at group replication start] |
| 27 |
CREATE TABLE t1 (c1 INT NOT NULL PRIMARY KEY) ENGINE=InnoDB; |
| 28 |
INSERT INTO t1 VALUES (2); |
| 29 |
INSERT INTO t1 VALUES (3); |
| 30 |
INSERT INTO t1 values (4); |
| 31 |
SET @@GLOBAL.DEBUG='+d,block_applier_updates'; |
| 32 |
server2 |
| 33 |
SET SESSION sql_log_bin= 0; |
| 34 |
call mtr.add_suppression("The requested GTID 'aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa:1' was already used, the transaction will rollback"); |
| 35 |
SET SESSION sql_log_bin= 1; |
| 36 |
include/start_group_replication.inc |
| 37 |
# Apply some transactions on the first member so that the queue of the second member is not empty. |
| 38 |
server1 |
| 39 |
SET GTID_NEXT= 'aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa:1'; |
| 40 |
INSERT INTO t1 VALUES (5); |
| 41 |
# Check for the transaction in the applier queue and then unblock the recovery. |
| 42 |
server2 |
| 43 |
[ The value of Count_Transactions_in_queue must be 2 when the applier has not processed the transaction queue ] |
| 44 |
server1 |
| 45 |
SET DEBUG_SYNC = "now WAIT_FOR applier_read_blocked"; |
| 46 |
SET @@GLOBAL.DEBUG='-d,block_applier_updates'; |
| 47 |
SET DEBUG_SYNC = "now SIGNAL resume_applier_read"; |
| 48 |
SET GTID_NEXT= 'AUTOMATIC'; |
| 49 |
server2 |
| 50 |
include/gr_wait_for_member_state.inc |
| 51 |
server1 |
| 52 |
include/assert.inc [The value of member_id should be equal to server UUID after starting group replication] |
| 53 |
include/assert.inc [The value of Count_Transactions_checked should be 5 after starting group replication] |
| 54 |
include/assert.inc [The value of Count_conflicts_detected should be 0 after starting group replication] |
| 55 |
include/assert.inc [The value of Count_Transactions_rows_validating should be 2 after starting group replication] |
| 56 |
include/assert.inc [The value of Transactions_committed_all_members should have server 1 GTIDs before server2 start] |
| 57 |
include/assert.inc [The value of Last_Conflict_free_transaction should be the gtid of the last applied transaction.] |
| 58 |
SET SESSION sql_log_bin= 0; |
| 59 |
include/gtid_utils.inc |
| 60 |
SET SESSION sql_log_bin= 1; |
| 61 |
[ The value of stable_set must be equal to the member GTID executed set ] |
| 62 |
include/assert.inc ['Transactions_committed_all_members must be equal to expected gtid value'] |
| 63 |
SET SESSION sql_log_bin= 0; |
| 64 |
include/gtid_utils_end.inc |
| 65 |
SET SESSION sql_log_bin= 1; |
| 66 |
include/diff_tables.inc [server1:t1, server2:t1] |
| 67 |
DROP TABLE t1; |
| 68 |
SET DEBUG_SYNC= 'RESET'; |
| 69 |
#################################### |
| 70 |
The values being checked after stop |
| 71 |
#################################### |
| 72 |
include/stop_group_replication.inc |
| 73 |
include/stop_group_replication.inc |