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

MDEV-32897 main suite test case prints extra row for metadata_lock_info query

- Added the parameter stats_persistent=0 for InnoDB engine.
- Before printing metadata_lock_info query, make sure that
InnoDB does complete purging.

Reviewed by: Marko Mäkelä
This commit is contained in:
Thirunarayanan Balathandayuthapani
2023-11-29 17:43:40 +05:30
parent 47fc64c19f
commit e996f77cd8
14 changed files with 83 additions and 19 deletions

View File

@ -1,6 +1,9 @@
#
# Testing which locks we get from all stages
#
SET @saved_frequency = @@GLOBAL.innodb_purge_rseg_truncate_frequency;
SET GLOBAL innodb_purge_rseg_truncate_frequency = 1;
InnoDB 0 transactions not purged
BACKUP STAGE START;
SELECT LOCK_MODE, LOCK_TYPE, TABLE_SCHEMA, TABLE_NAME FROM information_schema.metadata_lock_info;
LOCK_MODE LOCK_TYPE TABLE_SCHEMA TABLE_NAME
@ -29,7 +32,8 @@ connection default;
#
# testing if BACKUP STAGE FLUSH causes deadlocks with ALTER TABLE
#
create table t1 (a int) engine=innodb;
create table t1 (a int) stats_persistent= 0, engine=innodb;
InnoDB 0 transactions not purged
start transaction;
insert into t1 values (1);
connection con1;
@ -95,7 +99,8 @@ drop table t1;
#
# testing if BACKUP STAGE FLUSH causes deadlocks with DROP TABLE
#
create table t1 (a int) engine=innodb;
create table t1 (a int)stats_persistent=0, engine=innodb;
InnoDB 0 transactions not purged
start transaction;
insert into t1 values (1);
connection con1;
@ -122,6 +127,7 @@ connection default;
# Check if backup stage block_dll + concurrent drop table blocks select
#
create table t1 (a int) engine=innodb;
InnoDB 0 transactions not purged
backup stage start;
backup stage block_ddl;
connection con1;
@ -217,3 +223,4 @@ DROP TABLE t_permanent_myisam, t_permanent_innodb;
DROP TABLE t_con1_innodb, t_con1_myisam;
disconnect con1;
set global lock_wait_timeout=default;
SET GLOBAL innodb_purge_rseg_truncate_frequency = @saved_frequency;