CREATE TABLE t1 (f1 INTEGER) ENGINE=InnoDB;
CREATE TABLE t2 (f1 INTEGER) ENGINE=InnoDB;
CREATE TABLE t3 (f1 INTEGER) ENGINE=InnoDB;
CREATE TABLE t4 (f1 INTEGER) ENGINE=InnoDB;
connection node_2;
connection node_1;
SET SESSION wsrep_trx_fragment_size = 1;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
INSERT INTO t1 VALUES (1);
connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1;
connection node_1a;
SET GLOBAL wsrep_on=OFF;
RESET MASTER;
SET GLOBAL wsrep_on=ON;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
INSERT INTO t2 VALUES (1);
connection node_2;
SET GLOBAL wsrep_on=OFF;
RESET MASTER;
SET GLOBAL wsrep_on=ON;
SET AUTOCOMMIT=OFF;
SET SESSION wsrep_trx_fragment_size = 1;
START TRANSACTION;
INSERT INTO t3 VALUES (1);
connect node_2a, 127.0.0.1, root, , test, $NODE_MYPORT_2;
connection node_2a;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
INSERT INTO t4 VALUES (1);
connection node_1;
INSERT INTO t1 VALUES (2);
COMMIT;
connection node_1a;
INSERT INTO t2 VALUES (2);
COMMIT;
connection node_2;
INSERT INTO t3 VALUES (2);
COMMIT;
connection node_2a;
INSERT INTO t4 VALUES (2);
COMMIT;
connection node_1;
SELECT COUNT(*) = 2 FROM t4;
COUNT(*) = 2
1
include/show_binlog_events.inc
Log_name	Pos	Event_type	Server_id	End_log_pos	Info
mysqld-bin.000001	#	Gtid	#	#	BEGIN GTID #-#-#
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t1 VALUES (1)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t1)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t1 VALUES (2)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t1)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Xid	#	#	COMMIT /* XID */
mysqld-bin.000001	#	Gtid	#	#	BEGIN GTID #-#-#
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t2 VALUES (1)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t2)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t2 VALUES (2)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t2)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Xid	#	#	COMMIT /* XID */
mysqld-bin.000001	#	Gtid	#	#	BEGIN GTID #-#-#
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t3 VALUES (1)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t3)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t3 VALUES (2)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t3)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Xid	#	#	COMMIT /* XID */
mysqld-bin.000001	#	Gtid	#	#	BEGIN GTID #-#-#
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t4 VALUES (1)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t4)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t4 VALUES (2)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t4)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Xid	#	#	COMMIT /* XID */
connection node_2;
SELECT COUNT(*) = 2 FROM t4;
COUNT(*) = 2
1
include/show_binlog_events.inc
Log_name	Pos	Event_type	Server_id	End_log_pos	Info
mysqld-bin.000001	#	Gtid	#	#	BEGIN GTID #-#-#
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t1 VALUES (1)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t1)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t1 VALUES (2)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t1)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Xid	#	#	COMMIT /* XID */
mysqld-bin.000001	#	Gtid	#	#	BEGIN GTID #-#-#
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t2 VALUES (1)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t2)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t2 VALUES (2)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t2)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Xid	#	#	COMMIT /* XID */
mysqld-bin.000001	#	Gtid	#	#	BEGIN GTID #-#-#
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t3 VALUES (1)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t3)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t3 VALUES (2)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t3)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Xid	#	#	COMMIT /* XID */
mysqld-bin.000001	#	Gtid	#	#	BEGIN GTID #-#-#
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t4 VALUES (1)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t4)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Annotate_rows	#	#	INSERT INTO t4 VALUES (2)
mysqld-bin.000001	#	Table_map	#	#	table_id: # (test.t4)
mysqld-bin.000001	#	Write_rows_v1	#	#	table_id: # flags: STMT_END_F
mysqld-bin.000001	#	Xid	#	#	COMMIT /* XID */
DROP TABLE t1,t2,t3,t4;
