Commit 917a7386 authored by Kristian Nielsen's avatar Kristian Nielsen

MDEV-32819: main.show_explain failed in buildbot

The testcase had a race in two places where a KILL QUERY is made towards a
running query in another connection. The query can complete early so the kill
is lost, and the test fails due to expecting ER_QUERY_INTERRUPTED.

Fix by removing the KILL QUERY. It is not needed, as the query completes by
itself after SHOW EXPLAIN FOR.
Signed-off-by: default avatarKristian Nielsen <knielsen@knielsen-hq.org>
parent d018b909
...@@ -244,9 +244,7 @@ set @foo= (select max(a) from t0 where sin(a) >0); ...@@ -244,9 +244,7 @@ set @foo= (select max(a) from t0 where sin(a) >0);
connection default; connection default;
show explain for $thr2; show explain for $thr2;
ERROR HY000: Target is not executing an operation with a query plan ERROR HY000: Target is not executing an operation with a query plan
kill query $thr2;
connection con1; connection con1;
ERROR 70100: Query execution was interrupted
SET debug_dbug=@old_debug; SET debug_dbug=@old_debug;
# #
# Attempt SHOW EXPLAIN for an UPDATE # Attempt SHOW EXPLAIN for an UPDATE
...@@ -568,9 +566,14 @@ SELECT * FROM v1, t2; ...@@ -568,9 +566,14 @@ SELECT * FROM v1, t2;
connection default; connection default;
show explain for $thr2; show explain for $thr2;
ERROR HY000: Target is not executing an operation with a query plan ERROR HY000: Target is not executing an operation with a query plan
kill query $thr2;
connection con1; connection con1;
ERROR 70100: Query execution was interrupted a b
8 4
8 5
8 6
8 7
8 8
8 9
SET debug_dbug=@old_debug; SET debug_dbug=@old_debug;
DROP VIEW v1; DROP VIEW v1;
DROP TABLE t2, t3; DROP TABLE t2, t3;
......
...@@ -273,9 +273,7 @@ connection default; ...@@ -273,9 +273,7 @@ connection default;
--source include/wait_condition.inc --source include/wait_condition.inc
--error ER_TARGET_NOT_EXPLAINABLE --error ER_TARGET_NOT_EXPLAINABLE
evalp show explain for $thr2; evalp show explain for $thr2;
evalp kill query $thr2;
connection con1; connection con1;
--error ER_QUERY_INTERRUPTED
reap; reap;
SET debug_dbug=@old_debug; SET debug_dbug=@old_debug;
...@@ -504,9 +502,7 @@ connection default; ...@@ -504,9 +502,7 @@ connection default;
--source include/wait_condition.inc --source include/wait_condition.inc
--error ER_TARGET_NOT_EXPLAINABLE --error ER_TARGET_NOT_EXPLAINABLE
evalp show explain for $thr2; evalp show explain for $thr2;
evalp kill query $thr2;
connection con1; connection con1;
--error ER_QUERY_INTERRUPTED
reap; reap;
SET debug_dbug=@old_debug; SET debug_dbug=@old_debug;
DROP VIEW v1; DROP VIEW v1;
......
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