Commit 4438ff07 authored by Marko Mäkelä's avatar Marko Mäkelä

MDEV-20389: Refine the test case

Let us invoke wait_all_purged.inc right before the workload.
Starting with MDEV-12288 in MariaDB Server 10.3, also INSERT
generates purge workload. If we do not ensure that purge has
run to completion, the results on 10.3 and later could be
nondeterministic.
parent 2850b8d8
......@@ -6,7 +6,6 @@
#
SET @saved_frequency= @@GLOBAL.innodb_purge_rseg_truncate_frequency;
SET GLOBAL innodb_purge_rseg_truncate_frequency= 1;
InnoDB 0 transactions not purged
CREATE PROCEDURE insert_n(start int, end int)
BEGIN
DECLARE i INT DEFAULT start;
......@@ -52,6 +51,7 @@ connection default;
# Connect to default and record how many pages were accessed
# when selecting the record using the secondary key.
#
InnoDB 3 transactions not purged
SET @num_pages_1 = num_pages_get();
SELECT * FROM t1 force index (b);
a b c
......
......@@ -8,7 +8,6 @@
--source include/have_innodb.inc
SET @saved_frequency= @@GLOBAL.innodb_purge_rseg_truncate_frequency;
SET GLOBAL innodb_purge_rseg_truncate_frequency= 1;
--source include/wait_all_purged.inc
DELIMITER ~~;
CREATE PROCEDURE insert_n(start int, end int)
......@@ -65,6 +64,8 @@ connection default;
--echo # Connect to default and record how many pages were accessed
--echo # when selecting the record using the secondary key.
--echo #
--let $wait_all_purged=3
--source include/wait_all_purged.inc
SET @num_pages_1 = num_pages_get();
SELECT * FROM t1 force index (b);
SET @num_pages_2= num_pages_get();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment