1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MariaDB adjustments for Oracle Bug#23070734 fix

Split the test case so that a server restart is not needed.
Reduce the test cases and use a simpler mechanism for triggering
and waiting for purge.

fil_table_accessible(): Check if a table can be accessed without
enjoying MDL protection.
This commit is contained in:
Marko Mäkelä
2017-04-25 18:25:57 +03:00
parent 62dca454e7
commit 849af74a48
12 changed files with 211 additions and 180 deletions

View File

@ -0,0 +1,29 @@
#
# Bug #23070734 CONCURRENT TRUNCATE TABLES CAUSE STALLS
#
create table t1 (f1 int ,f2 int,key(f2)) engine=innodb;
begin;
insert into t1 values (10,45),(20,78),(30,88),(40,23),(50,78),(60,11),(70,56),(80,90);
delete from t1;
connect con2,localhost,root,,;
START TRANSACTION WITH CONSISTENT SNAPSHOT;
connection default;
SET @saved_frequency = @@GLOBAL.innodb_purge_rseg_truncate_frequency;
SET GLOBAL innodb_purge_rseg_truncate_frequency = 1;
commit;
connect con1,localhost,root,,;
SET DEBUG_SYNC= 'buffer_pool_scan SIGNAL started WAIT_FOR finish_scan';
truncate table t1;
connection con2;
SET DEBUG_SYNC= 'now WAIT_FOR started';
COMMIT;
disconnect con2;
connection default;
InnoDB 0 transactions not purged
SET GLOBAL innodb_purge_rseg_truncate_frequency = @saved_frequency;
SET DEBUG_SYNC = 'now SIGNAL finish_scan';
SET DEBUG_SYNC = 'RESET';
connection con1;
disconnect con1;
connection default;
drop table t1;