make plugins.processlist more robust
This commit is contained in:
parent
00ccff48af
commit
78a0646fe4
@ -2,10 +2,8 @@ create table t1 (a int) engine=innodb;
|
|||||||
start transaction;
|
start transaction;
|
||||||
insert t1 values (1);
|
insert t1 values (1);
|
||||||
connect con2,localhost,root;
|
connect con2,localhost,root;
|
||||||
state from show engine innodb status
|
state from show engine innodb status, must be empty
|
||||||
|
|
||||||
state from show processlist
|
|
||||||
|
|
||||||
disconnect con2;
|
disconnect con2;
|
||||||
connection default;
|
connection default;
|
||||||
drop table t1;
|
drop table t1;
|
||||||
|
@ -8,11 +8,12 @@ start transaction;
|
|||||||
insert t1 values (1);
|
insert t1 values (1);
|
||||||
let id=`select connection_id()`;
|
let id=`select connection_id()`;
|
||||||
connect con2,localhost,root;
|
connect con2,localhost,root;
|
||||||
|
let $wait_condition=select state='' from information_schema.processlist where id = $id;
|
||||||
|
--source include/wait_condition.inc
|
||||||
replace_regex /\"/-/; #"
|
replace_regex /\"/-/; #"
|
||||||
let s=`show engine innodb status`;
|
let s=`show engine innodb status`;
|
||||||
disable_query_log;
|
disable_query_log;
|
||||||
eval select regexp_replace("$s", '(?s)^.*MySQL thread id $id,.*root([^\n]*)\n.*', '\\\\1') as `state from show engine innodb status`;
|
eval select regexp_replace("$s", '(?s)^.*MySQL thread id $id,.*root([^\n]*)\n.*', '\\\\1') as `state from show engine innodb status, must be empty`;
|
||||||
eval select state as `state from show processlist` from information_schema.processlist where id = $id;
|
|
||||||
enable_query_log;
|
enable_query_log;
|
||||||
disconnect con2;
|
disconnect con2;
|
||||||
connection default;
|
connection default;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user