fix more sporadic failures on main.kill

sometimes `KILL QUERY ID @id` was executed before the previous
`send SELECT SLEEP(1000)` has reached the parser. As the statement
resets the kill status before execution, the effect of the KILL
was ignored.
This commit is contained in:
Sergei Golubchik 2022-11-30 22:49:44 +01:00
parent 401ae95a60
commit 1547e55489

View file

@ -542,7 +542,7 @@ connection default;
--echo #
send SELECT SLEEP(1000);
connection con1;
let $wait_condition= SELECT @id:=QUERY_ID FROM INFORMATION_SCHEMA.PROCESSLIST WHERE INFO='SELECT SLEEP(1000)';
let $wait_condition= SELECT @id:=QUERY_ID FROM INFORMATION_SCHEMA.PROCESSLIST WHERE INFO='SELECT SLEEP(1000)' AND STATE='User sleep';
source include/wait_condition.inc;
KILL QUERY ID @id;
connection default;
@ -560,7 +560,7 @@ CREATE USER u1@localhost;
send SELECT SLEEP(1000);
connection con1;
let $wait_condition= SELECT @id:=QUERY_ID FROM INFORMATION_SCHEMA.PROCESSLIST WHERE INFO='SELECT SLEEP(1000)';
let $wait_condition= SELECT @id:=QUERY_ID FROM INFORMATION_SCHEMA.PROCESSLIST WHERE INFO='SELECT SLEEP(1000)' AND STATE='User sleep';
source include/wait_condition.inc;
let $id= `SELECT @id`;