mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
MDEV-35049: Improve test coverage
innodb.lock_memory: Allow the test to run with ./mtr --mysqld=--loose-innodb-adaptive-hash-index. main.row_filter_innodb,ahi: A new combination for innodb_adaptive_hash_index=ON.
This commit is contained in:
29
mysql-test/main/rowid_filter_innodb,ahi.rdiff
Normal file
29
mysql-test/main/rowid_filter_innodb,ahi.rdiff
Normal file
@@ -0,0 +1,29 @@
|
||||
--- rowid_filter_innodb.result
|
||||
+++ rowid_filter_innodb,ahi.result
|
||||
@@ -2,7 +2,7 @@
|
||||
SET @save_stats_persistent=@@GLOBAL.innodb_stats_persistent;
|
||||
SET GLOBAL innodb_stats_persistent=0;
|
||||
SET @save_ahi=@@GLOBAL.innodb_adaptive_hash_index;
|
||||
-SET GLOBAL innodb_adaptive_hash_index=OFF;
|
||||
+SET GLOBAL innodb_adaptive_hash_index=ON;
|
||||
DROP DATABASE IF EXISTS dbt3_s001;
|
||||
CREATE DATABASE dbt3_s001;
|
||||
use dbt3_s001;
|
||||
@@ -2059,7 +2059,7 @@
|
||||
"r_table_time_ms": "REPLACED",
|
||||
"r_other_time_ms": "REPLACED",
|
||||
"r_engine_stats": {
|
||||
- "pages_accessed": 84
|
||||
+ "pages_accessed": 6
|
||||
},
|
||||
"filtered": "REPLACED",
|
||||
"r_total_filtered": 2.43902439,
|
||||
@@ -2227,7 +2227,7 @@
|
||||
"r_table_time_ms": "REPLACED",
|
||||
"r_other_time_ms": "REPLACED",
|
||||
"r_engine_stats": {
|
||||
- "pages_accessed": 84
|
||||
+ "pages_accessed": 2
|
||||
},
|
||||
"filtered": "REPLACED",
|
||||
"r_total_filtered": 2.43902439,
|
2
mysql-test/main/rowid_filter_innodb.combinations
Normal file
2
mysql-test/main/rowid_filter_innodb.combinations
Normal file
@@ -0,0 +1,2 @@
|
||||
[normal]
|
||||
[ahi]
|
@@ -1,6 +1,8 @@
|
||||
SET SESSION DEFAULT_STORAGE_ENGINE='InnoDB';
|
||||
SET @save_stats_persistent=@@GLOBAL.innodb_stats_persistent;
|
||||
SET GLOBAL innodb_stats_persistent=0;
|
||||
SET @save_ahi=@@GLOBAL.innodb_adaptive_hash_index;
|
||||
SET GLOBAL innodb_adaptive_hash_index=OFF;
|
||||
DROP DATABASE IF EXISTS dbt3_s001;
|
||||
CREATE DATABASE dbt3_s001;
|
||||
use dbt3_s001;
|
||||
@@ -2287,6 +2289,7 @@ ALTER TABLE orders DROP COLUMN o_totaldiscount;
|
||||
DROP VIEW v1;
|
||||
DROP DATABASE dbt3_s001;
|
||||
use test;
|
||||
SET GLOBAL innodb_adaptive_hash_index=@save_ahi;
|
||||
SET GLOBAL innodb_stats_persistent=@save_stats_persistent;
|
||||
#
|
||||
# MDEV-18755: possible RORI-plan and possible plan with range filter
|
||||
|
@@ -13,8 +13,17 @@ SET SESSION DEFAULT_STORAGE_ENGINE='InnoDB';
|
||||
SET @save_stats_persistent=@@GLOBAL.innodb_stats_persistent;
|
||||
SET GLOBAL innodb_stats_persistent=0;
|
||||
|
||||
SET @save_ahi=@@GLOBAL.innodb_adaptive_hash_index;
|
||||
if ($MTR_COMBINATION_AHI) {
|
||||
SET GLOBAL innodb_adaptive_hash_index=ON;
|
||||
}
|
||||
if (!$MTR_COMBINATION_AHI) {
|
||||
SET GLOBAL innodb_adaptive_hash_index=OFF;
|
||||
}
|
||||
|
||||
--source rowid_filter.test
|
||||
|
||||
SET GLOBAL innodb_adaptive_hash_index=@save_ahi;
|
||||
SET GLOBAL innodb_stats_persistent=@save_stats_persistent;
|
||||
|
||||
--source include/have_sequence.inc
|
||||
|
@@ -1,6 +1,8 @@
|
||||
#
|
||||
# MDEV-28800 SIGABRT due to running out of memory for InnoDB locks
|
||||
#
|
||||
SET @save_ahi=@@GLOBAL.innodb_adaptive_hash_index;
|
||||
SET GLOBAL innodb_adaptive_hash_index=OFF;
|
||||
CREATE TABLE t1 (col1 INT) ENGINE=InnoDB;
|
||||
INSERT INTO t1 VALUES (1),(2),(3),(4);
|
||||
INSERT INTO t1 SELECT * FROM t1;
|
||||
@@ -18,3 +20,4 @@ SELECT COUNT(*) FROM t1;
|
||||
COUNT(*)
|
||||
65552
|
||||
DROP TABLE t1;
|
||||
SET GLOBAL innodb_adaptive_hash_index=@save_ahi;
|
||||
|
@@ -5,6 +5,9 @@
|
||||
--echo # MDEV-28800 SIGABRT due to running out of memory for InnoDB locks
|
||||
--echo #
|
||||
|
||||
SET @save_ahi=@@GLOBAL.innodb_adaptive_hash_index;
|
||||
SET GLOBAL innodb_adaptive_hash_index=OFF;
|
||||
|
||||
CREATE TABLE t1 (col1 INT) ENGINE=InnoDB;
|
||||
|
||||
INSERT INTO t1 VALUES (1),(2),(3),(4);
|
||||
@@ -27,3 +30,4 @@ COMMIT;
|
||||
SELECT COUNT(*) FROM t1;
|
||||
|
||||
DROP TABLE t1;
|
||||
SET GLOBAL innodb_adaptive_hash_index=@save_ahi;
|
||||
|
Reference in New Issue
Block a user