mirror of
https://github.com/MariaDB/server.git
synced 2025-01-19 13:32:33 +01:00
Fix for team tree failure. Synchronously wait for the query state
to reach the desired value.
This commit is contained in:
parent
566ca2ba75
commit
d58c9e089e
2 changed files with 13 additions and 1 deletions
|
@ -1,3 +1,4 @@
|
|||
set @@global.concurrent_insert= 0;
|
||||
drop table if exists t1;
|
||||
create table t1 (kill_id int);
|
||||
insert into t1 values(connection_id());
|
||||
|
|
|
@ -12,6 +12,10 @@
|
|||
|
||||
-- source include/have_debug.inc
|
||||
|
||||
# Disable concurrent inserts to avoid test failures when reading the
|
||||
# connection id which was inserted into a table by another thread.
|
||||
set @@global.concurrent_insert= 0;
|
||||
|
||||
connect (con1,localhost,root,,);
|
||||
connect (con2,localhost,root,,);
|
||||
connection con1;
|
||||
|
@ -34,7 +38,14 @@ send flush tables with read lock;
|
|||
connection con2;
|
||||
select ((@id := kill_id) - kill_id) from t1;
|
||||
|
||||
--sleep 2 # leave time for FLUSH to block
|
||||
# Wait for the debug sync point, test won't run on non-debug
|
||||
# builds anyway.
|
||||
let $wait_condition=
|
||||
select count(*) = 1 from information_schema.processlist
|
||||
where state = "Waiting for all running commits to finish"
|
||||
and info = "flush tables with read lock";
|
||||
--source include/wait_condition.inc
|
||||
|
||||
kill connection @id;
|
||||
|
||||
connection con1;
|
||||
|
|
Loading…
Reference in a new issue