| 1 |
RESET MASTER; |
| 2 |
CREATE TABLE t1 (a INT PRIMARY KEY, b MEDIUMTEXT) ENGINE=Innodb; |
| 3 |
connect con1,localhost,root,,; |
| 4 |
SET DEBUG_SYNC= "at_unlog_xa_prepare SIGNAL con1_ready WAIT_FOR con1_go"; |
| 5 |
XA START '1'; |
| 6 |
INSERT INTO t1 SET a=1; |
| 7 |
XA END '1'; |
| 8 |
XA PREPARE '1';; |
| 9 |
connection default; |
| 10 |
SET DEBUG_SYNC= "now WAIT_FOR con1_ready"; |
| 11 |
FLUSH LOGS; |
| 12 |
FLUSH LOGS; |
| 13 |
FLUSH LOGS; |
| 14 |
show binary logs; |
| 15 |
Log_name File_size |
| 16 |
master-bin.000001 # |
| 17 |
master-bin.000002 # |
| 18 |
master-bin.000003 # |
| 19 |
master-bin.000004 # |
| 20 |
include/show_binlog_events.inc |
| 21 |
Log_name Pos Event_type Server_id End_log_pos Info |
| 22 |
master-bin.000004 # Format_desc # # SERVER_VERSION, BINLOG_VERSION |
| 23 |
master-bin.000004 # Gtid_list # # [#-#-#] |
| 24 |
master-bin.000004 # Binlog_checkpoint # # master-bin.000001 |
| 25 |
SET DEBUG_SYNC= "now SIGNAL con1_go"; |
| 26 |
connection con1; |
| 27 |
*** master-bin.000004 checkpoint must show up now *** |
| 28 |
connection con1; |
| 29 |
XA ROLLBACK '1'; |
| 30 |
SET debug_sync = 'reset'; |
| 31 |
connection default; |
| 32 |
DROP TABLE t1; |
| 33 |
SET debug_sync = 'reset'; |