mariadb/mysql-test/suite/galera/r/MDEV-20793.result
sjaakola 74b3d4252a MDEV-27218 mtr test galera.MDEV-20793 has sporadic false positive failures
Fixes to make the galera.MDEV-20793 test deterministic.
Specifically, after --send COMMIT, there is now a sync point to catch a known state of the COMMIT execution
2021-12-10 12:10:42 +02:00

44 lines
1.6 KiB
Text

connection node_2;
connection node_1;
CREATE TABLE t1 (f1 INT PRIMARY KEY, f2 INT);
INSERT INTO t1 VALUES (1, 0), (5, 0);
connection node_1_ctrl;
SET SESSION wsrep_sync_wait = 0;
SET GLOBAL wsrep_slave_threads = 2;
connection node_1;
SET SESSION wsrep_retry_autocommit = 0;
START TRANSACTION;
UPDATE t1 SET f2 = 1;
connection node_1_ctrl;
SET GLOBAL wsrep_provider_options = 'dbug=d,apply_monitor_slave_enter_sync';
connection node_2;
INSERT INTO t1 VALUES (2, 2);
connection node_1_ctrl;
SET SESSION wsrep_on = 0;
SET SESSION wsrep_on = 1;
SET GLOBAL wsrep_provider_options = 'dbug=';
SET GLOBAL wsrep_provider_options = 'dbug=d,local_monitor_slave_enter_sync';
connection node_2;
UPDATE t1 SET f2 = 2 WHERE f1 = 5;
connection node_1_ctrl;
SET SESSION wsrep_on = 0;
SET SESSION wsrep_on = 1;
SET GLOBAL wsrep_provider_options = 'dbug=';
SET GLOBAL wsrep_provider_options = 'dbug=d,after_replicate_sync';
connection node_1;
SET SESSION debug_sync = "wsrep_before_replay SIGNAL reached WAIT_FOR continue";
COMMIT;
connection node_1_ctrl;
SET SESSION wsrep_on = 0;
SET SESSION wsrep_on = 1;
SET GLOBAL wsrep_provider_options = 'signal=after_replicate_sync';
SET GLOBAL wsrep_provider_options = 'signal=apply_monitor_slave_enter_sync';
SET SESSION debug_sync = "now WAIT_FOR reached";
SET GLOBAL wsrep_provider_options = 'signal=local_monitor_slave_enter_sync';
SET GLOBAL wsrep_provider_options = 'dbug=';
SET SESSION debug_sync = "now SIGNAL continue";
connection node_1;
ERROR 40001: Deadlock found when trying to get lock; try restarting transaction
SET debug_sync = "RESET";
DROP TABLE t1;
SET GLOBAL wsrep_slave_threads = 1;