Commit 2fed6607 authored by Magne Mahre's avatar Magne Mahre

Bug#47017 rpl_timezone fails on PB-2 with mismatch error

The bug is caused by a race condition between the 
INSERT DELAYED thread and the client thread's FLUSH TABLE.  The 
FLUSH TABLE does not guarantee (as is (wrongly) suggested in the 
test case) that the INSERT DELAYED is ever executed.  The 
execution of the test case will thus not be deterministic.

The fix has been to do a deterministic verification that both
threads are complete by checking the content of the table.
parent 8f32ccff
...@@ -179,8 +179,11 @@ insert into t1 values('2008-12-23 19:39:39',1); ...@@ -179,8 +179,11 @@ insert into t1 values('2008-12-23 19:39:39',1);
--connection master1 --connection master1
SET @@session.time_zone='+02:00'; SET @@session.time_zone='+02:00';
insert delayed into t1 values ('2008-12-23 19:39:39',2); insert delayed into t1 values ('2008-12-23 19:39:39',2);
# Forces table t1 to be closed and flushes the query cache.
# This makes sure that 'delayed insert' is executed before next statement. # wait for the delayed insert to be executed
let $wait_condition= SELECT date FROM t1 WHERE a=2;
--source include/wait_condition.inc
flush table t1; flush table t1;
flush logs; flush logs;
select * from t1; select * from t1;
......
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