Commit 86c3c0b0 authored by aelkin/elkin@koti.dsl.inet.fi's avatar aelkin/elkin@koti.dsl.inet.fi

Merge aelkin@bk-internal.mysql.com:/home/bk/mysql-5.0-rpl

into  koti.dsl.inet.fi:/home/elkin/MySQL/TEAM/FIXES/5.0/bug27571_asyn_killed_flags
parents 9c979676 b9e4fdb2
...@@ -17,18 +17,22 @@ delete from t2; ...@@ -17,18 +17,22 @@ delete from t2;
insert into t1 values (1,1),(2,2); insert into t1 values (1,1),(2,2);
begin; begin;
update t1 set b=11 where a=2; update t1 set b=11 where a=2;
begin;
update t1 set b=b+10; update t1 set b=b+10;
kill query ID; kill query ID;
rollback; rollback;
rollback;
select * from t1 order by a /* must be the same as before (1,1),(2,2) */; select * from t1 order by a /* must be the same as before (1,1),(2,2) */;
a b a b
1 1 1 1
2 2 2 2
begin; begin;
delete from t1 where a=2; delete from t1 where a=2;
begin;
delete from t1 where a=2; delete from t1 where a=2;
kill query ID; kill query ID;
rollback; rollback;
rollback;
select * from t1 order by a /* must be the same as before (1,1),(2,2) */; select * from t1 order by a /* must be the same as before (1,1),(2,2) */;
a b a b
1 1 1 1
......
...@@ -79,6 +79,7 @@ begin; update t1 set b=11 where a=2; ...@@ -79,6 +79,7 @@ begin; update t1 set b=11 where a=2;
connection con2; connection con2;
let $ID= `select connection_id()`; let $ID= `select connection_id()`;
begin;
send update t1 set b=b+10; send update t1 set b=b+10;
connection con1; connection con1;
...@@ -86,9 +87,18 @@ connection con1; ...@@ -86,9 +87,18 @@ connection con1;
eval kill query $ID; eval kill query $ID;
rollback; rollback;
# Bug #32148 killi query may be ineffective
# forced to comment out the test's outcome
# and mask out ineffective ER_QUERY_INTERRUPTED
# todo1: revert back upon fixing bug#32148
# todo2: the tests need refining in that
# killing should wait till the victim requested
# its lock (wait_condition available in 5.1 tests)
connection con2; connection con2;
--error 0,ER_QUERY_INTERRUPTED --error 0,ER_QUERY_INTERRUPTED
reap; reap;
rollback;
select * from t1 order by a /* must be the same as before (1,1),(2,2) */; select * from t1 order by a /* must be the same as before (1,1),(2,2) */;
# #
...@@ -123,6 +133,7 @@ begin; delete from t1 where a=2; ...@@ -123,6 +133,7 @@ begin; delete from t1 where a=2;
connection con2; connection con2;
let $ID= `select connection_id()`; let $ID= `select connection_id()`;
begin;
send delete from t1 where a=2; send delete from t1 where a=2;
connection con1; connection con1;
...@@ -133,8 +144,11 @@ rollback; ...@@ -133,8 +144,11 @@ rollback;
connection con2; connection con2;
--error 0,ER_QUERY_INTERRUPTED --error 0,ER_QUERY_INTERRUPTED
reap; reap;
rollback;
# todo1,2 above
select * from t1 order by a /* must be the same as before (1,1),(2,2) */; select * from t1 order by a /* must be the same as before (1,1),(2,2) */;
# #
# multi delete # multi delete
# the same as for multi-update # the same as for multi-update
...@@ -178,6 +192,7 @@ rollback; ...@@ -178,6 +192,7 @@ rollback;
connection con2; connection con2;
--error 0,ER_QUERY_INTERRUPTED --error 0,ER_QUERY_INTERRUPTED
reap; reap;
# todo 1,2 above
rollback; rollback;
select * from t1 /* must be the same as before (1,1),(2,2) */; select * from t1 /* must be the same as before (1,1),(2,2) */;
......
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