Debian Codegraph @

mysql-test/suite/innodb/r/purge_pessimistic.result

raw
1 #
2 # MDEV-35508: Race condition between purge and secondary index INSERT or UPDATE
3 #
4 SET @old_debug_dbug = @@global.debug_dbug;
5 CREATE TABLE t1(col1 INT PRIMARY KEY, col2 int, KEY k1(col2)) ENGINE=Innodb;
6 INSERT INTO t1 VALUES(1, 100);
7 CREATE TABLE t2(col1 INT PRIMARY KEY) Engine=Innodb;
8 InnoDB 0 transactions not purged
9 START TRANSACTION;
10 INSERT INTO t2 VALUES(10);
11 SET DEBUG_SYNC='RESET';
12 SET GLOBAL debug_dbug= "+d,btr_force_pessimistic_delete";
13 SET GLOBAL debug_dbug= "+d,enable_row_purge_sec_tree_sync";
14 connect con1,localhost,root;
15 UPDATE t1 SET col2 = 200 WHERE col1 = 1;
16 connection default;
17 SET DEBUG_SYNC= 'now WAIT_FOR purge_sec_tree_begin';
18 SET GLOBAL debug_dbug= "-d,enable_row_purge_sec_tree_sync";
19 UPDATE t1 SET col2 = 100 WHERE col1 = 1;
20 SET DEBUG_SYNC= 'now SIGNAL purge_sec_tree_execute';
21 COMMIT;
22 InnoDB 0 transactions not purged
23 disconnect con1;
24 SELECT * FROM t1;
25 col1 col2
26 1 100
27 CHECK TABLE t1;
28 Table Op Msg_type Msg_text
29 test.t1 check status OK
30 DROP TABLE t1;
31 SELECT * FROM t2;
32 col1
33 10
34 DROP TABLE t2;
35 SET @@GLOBAL.debug_dbug = @old_debug_dbug;
36 SET DEBUG_SYNC='RESET';