1# 2# MDEV-7793 - Race condition between XA COMMIT/ROLLBACK and disconnect 3# 4# Note that this test is meaningful only with valgrind. 5connect con1, localhost, root; 6connect con2, localhost, root; 7connection con1; 8XA START 'xatest'; 9XA END 'xatest'; 10XA PREPARE 'xatest'; 11connection con2; 12SET debug_sync='xa_after_search SIGNAL parked WAIT_FOR go'; 13XA COMMIT 'xatest'; 14connection default; 15SET debug_sync='now WAIT_FOR parked'; 16disconnect con1; 17# Waiting for thread to get deleted 18SET debug_sync='now SIGNAL go'; 19connection con2; 20ERROR XAE04: XAER_NOTA: Unknown XID 21*** Must have 'xatest' in the list 22XA RECOVER; 23formatID gtrid_length bqual_length data 241 6 0 xatest 25XA COMMIT 'xatest'; 26disconnect con2; 27connection default; 28SET debug_sync='RESET'; 29connect con1, localhost, root; 30connect con2, localhost, root; 31connection con1; 32XA START 'xatest'; 33XA END 'xatest'; 34XA PREPARE 'xatest'; 35connection con2; 36SET debug_sync='xa_after_search SIGNAL parked WAIT_FOR go'; 37XA ROLLBACK 'xatest'; 38connection default; 39SET debug_sync='now WAIT_FOR parked'; 40disconnect con1; 41# Waiting for thread to get deleted 42SET debug_sync='now SIGNAL go'; 43connection con2; 44ERROR XAE04: XAER_NOTA: Unknown XID 45*** Must have 'xatest' in the list 46XA RECOVER; 47formatID gtrid_length bqual_length data 481 6 0 xatest 49XA ROLLBACK 'xatest'; 50disconnect con2; 51connection default; 52SET debug_sync='RESET'; 53