Commit fe4eacde authored by Alexey Botchkov's avatar Alexey Botchkov

MDEV-17683 sys_vars.delayed_insert_limit_func fails in buildbot with wrong result.

Test fixed to be deterministic.
parent edb6e2b9
...@@ -51,14 +51,12 @@ INSERT DELAYED INTO t1 VALUES('39','1','1'); ...@@ -51,14 +51,12 @@ INSERT DELAYED INTO t1 VALUES('39','1','1');
INSERT DELAYED INTO t1 VALUES('40','1','1'); INSERT DELAYED INTO t1 VALUES('40','1','1');
INSERT DELAYED INTO t1 VALUES('41','1','1'); INSERT DELAYED INTO t1 VALUES('41','1','1');
INSERT DELAYED INTO t1 VALUES('42','1','1'); INSERT DELAYED INTO t1 VALUES('42','1','1');
INSERT DELAYED INTO t1 VALUES('43','1','1');| INSERT DELAYED INTO t1 VALUES('43','1','1');
** Connection con0 ** ** Connection con0 **
SELECT COUNT(*) FROM t1; SELECT COUNT(*) FROM t1;
** Connection default ** ** Connection default **
** Wait till con0 is blocked ** ** Wait till con0 is blocked **
UNLOCK TABLES; UNLOCK TABLES;
** Connection con1 **
Asynchronous "reap" result
** Connection con0 ** ** Connection con0 **
Asynchronous "reap" result Asynchronous "reap" result
The next result suffers from The next result suffers from
...@@ -84,7 +82,6 @@ INSERT INTO t1 VALUES('5'); ...@@ -84,7 +82,6 @@ INSERT INTO t1 VALUES('5');
INSERT INTO t1 VALUES('6'); INSERT INTO t1 VALUES('6');
LOCK TABLE v1 READ; LOCK TABLE v1 READ;
** Connection con1 ** ** Connection con1 **
Asynchronous execute
INSERT DELAYED INTO t1 VALUES('7'); INSERT DELAYED INTO t1 VALUES('7');
INSERT DELAYED INTO t1 VALUES('8'); INSERT DELAYED INTO t1 VALUES('8');
INSERT DELAYED INTO t1 VALUES('9'); INSERT DELAYED INTO t1 VALUES('9');
...@@ -100,23 +97,22 @@ INSERT DELAYED INTO t1 VALUES('18'); ...@@ -100,23 +97,22 @@ INSERT DELAYED INTO t1 VALUES('18');
INSERT DELAYED INTO t1 VALUES('19'); INSERT DELAYED INTO t1 VALUES('19');
INSERT DELAYED INTO t1 VALUES('20'); INSERT DELAYED INTO t1 VALUES('20');
INSERT DELAYED INTO t1 VALUES('21'); INSERT DELAYED INTO t1 VALUES('21');
INSERT DELAYED INTO t1 VALUES('22');| INSERT DELAYED INTO t1 VALUES('22');
** Connection con0 ** ** Connection con0 **
Asynchronous execute Asynchronous execute
SELECT COUNT(*) BETWEEN 6 AND 22 FROM t1; SELECT COUNT(*) FROM t1;
** Connection default ** ** Connection default **
** Wait till con0 is blocked ** ** Wait till con0 is blocked **
UNLOCK TABLES; UNLOCK TABLES;
** Connection con1 **
** Connection con0 ** ** Connection con0 **
Asynchronous "reap" result Asynchronous "reap" result
COUNT(*) BETWEEN 6 AND 22 COUNT(*)
1 22
** Connection default** ** Connection default**
Checking if the delayed insert gives the same result afterwards Checking if the delayed insert gives the same result afterwards
SELECT COUNT(*) BETWEEN 6 AND 22 FROM t1; SELECT COUNT(*) FROM t1;
COUNT(*) BETWEEN 6 AND 22 COUNT(*)
1 22
** Connection default** ** Connection default**
DROP TABLE t1; DROP TABLE t1;
DROP VIEW v1; DROP VIEW v1;
......
...@@ -66,8 +66,6 @@ LOCK TABLE v1 READ; ...@@ -66,8 +66,6 @@ LOCK TABLE v1 READ;
--echo ** Connection con1 ** --echo ** Connection con1 **
connection con1; connection con1;
delimiter |;
send
INSERT DELAYED INTO t1 VALUES('7','1','1'); INSERT DELAYED INTO t1 VALUES('7','1','1');
INSERT DELAYED INTO t1 VALUES('8','1','1'); INSERT DELAYED INTO t1 VALUES('8','1','1');
INSERT DELAYED INTO t1 VALUES('9','1','1'); INSERT DELAYED INTO t1 VALUES('9','1','1');
...@@ -104,8 +102,7 @@ INSERT DELAYED INTO t1 VALUES('39','1','1'); ...@@ -104,8 +102,7 @@ INSERT DELAYED INTO t1 VALUES('39','1','1');
INSERT DELAYED INTO t1 VALUES('40','1','1'); INSERT DELAYED INTO t1 VALUES('40','1','1');
INSERT DELAYED INTO t1 VALUES('41','1','1'); INSERT DELAYED INTO t1 VALUES('41','1','1');
INSERT DELAYED INTO t1 VALUES('42','1','1'); INSERT DELAYED INTO t1 VALUES('42','1','1');
INSERT DELAYED INTO t1 VALUES('43','1','1');| INSERT DELAYED INTO t1 VALUES('43','1','1');
delimiter ;|
--echo ** Connection con0 ** --echo ** Connection con0 **
connection con0; connection con0;
...@@ -126,11 +123,6 @@ let $wait_condition= ...@@ -126,11 +123,6 @@ let $wait_condition=
--source include/wait_condition.inc --source include/wait_condition.inc
UNLOCK TABLES; UNLOCK TABLES;
--echo ** Connection con1 **
connection con1;
--echo Asynchronous "reap" result
reap;
--echo ** Connection con0 ** --echo ** Connection con0 **
connection con0; connection con0;
--echo Asynchronous "reap" result --echo Asynchronous "reap" result
...@@ -170,10 +162,6 @@ LOCK TABLE v1 READ; ...@@ -170,10 +162,6 @@ LOCK TABLE v1 READ;
--echo ** Connection con1 ** --echo ** Connection con1 **
connection con1; connection con1;
--echo Asynchronous execute
delimiter |;
send
INSERT DELAYED INTO t1 VALUES('7'); INSERT DELAYED INTO t1 VALUES('7');
INSERT DELAYED INTO t1 VALUES('8'); INSERT DELAYED INTO t1 VALUES('8');
INSERT DELAYED INTO t1 VALUES('9'); INSERT DELAYED INTO t1 VALUES('9');
...@@ -189,9 +177,7 @@ INSERT DELAYED INTO t1 VALUES('18'); ...@@ -189,9 +177,7 @@ INSERT DELAYED INTO t1 VALUES('18');
INSERT DELAYED INTO t1 VALUES('19'); INSERT DELAYED INTO t1 VALUES('19');
INSERT DELAYED INTO t1 VALUES('20'); INSERT DELAYED INTO t1 VALUES('20');
INSERT DELAYED INTO t1 VALUES('21'); INSERT DELAYED INTO t1 VALUES('21');
INSERT DELAYED INTO t1 VALUES('22');| INSERT DELAYED INTO t1 VALUES('22');
delimiter ;|
--echo ** Connection con0 ** --echo ** Connection con0 **
connection con0; connection con0;
...@@ -202,7 +188,7 @@ let $wait_condition= ...@@ -202,7 +188,7 @@ let $wait_condition=
--echo Asynchronous execute --echo Asynchronous execute
# Due to performance and server behaveiour the test observes values between 6 and 22. # Due to performance and server behaveiour the test observes values between 6 and 22.
# In any case the value must not be outside of that range. # In any case the value must not be outside of that range.
let $my_select= SELECT COUNT(*) BETWEEN 6 AND 22 FROM t1; let $my_select= SELECT COUNT(*) FROM t1;
send; send;
eval $my_select; eval $my_select;
...@@ -215,10 +201,6 @@ let $wait_condition= ...@@ -215,10 +201,6 @@ let $wait_condition=
--source include/wait_condition.inc --source include/wait_condition.inc
UNLOCK TABLES; UNLOCK TABLES;
--echo ** Connection con1 **
connection con1;
reap;
--echo ** Connection con0 ** --echo ** Connection con0 **
connection con0; connection con0;
--echo Asynchronous "reap" result --echo Asynchronous "reap" result
......
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