Skip to content

Commit fe41613

Browse files
author
Deepthi Eranti_Sreenivas
committed
Bug#22084462:MYSQL TEST BINLOG.BINLOG_ROW_MIX_INNODB_MYISAM FAILS
Reason for failure: The test case uses a subtest '/extra/binlog_tests/mix_innodb_myisam_binlog.test'. Here,in the test for BUG#7947 section,it is creating some temporary tables using connection 'con2' and then closing this connection and observing that the 'DROP TEMP TABLE' statements were properly binary logged. It fails with a Result Content Mismatch because, on issuing the disconnection of "con2", the test case does not wait until the server cleanup the thread for that connection before updating the binary log events. Fix: Included include/assert_binlog_events.inc which waits for the binlog events and also assert that the temporary tables were dropped. 'extra/binlog_tests/mix_innodb_myisam_binlog.test' subtest is used in 'binlog_row_mix_innodb_myisam.test' and 'binlog_stm_mix_innodb_myisam.test' Result files for both these tests('binlog_row_mix_innodb_myisam.result' and 'binlog_stm_mix_innodb_myisam.result') are updated. In include/assert_binlog_events.inc,the description of $slave_timeout did not specify the unit of time. Fix: Changed the decription in 'Usage' of assert_binlog_events.inc.
1 parent 11758ec commit fe41613

File tree

4 files changed

+20
-2
lines changed

4 files changed

+20
-2
lines changed

mysql-test/extra/binlog_tests/mix_innodb_myisam_binlog.test

+12-1
Original file line numberDiff line numberDiff line change
@@ -234,9 +234,20 @@ set autocommit=1;
234234
insert into t0 select GET_LOCK("lock1",null);
235235
set autocommit=0;
236236
create table t2 (n int) engine=innodb;
237-
insert into t2 values (3);
237+
insert into t2 values (3);
238+
# Saving the binlog filename and position
239+
--source include/save_binlog_position.inc
238240
disconnect con2;
241+
# Wait until con2 disconnects
242+
--source include/wait_until_disconnected.inc
239243
connection con3;
244+
# Bug #22084462 - MYSQL TEST BINLOG.BINLOG_ROW_MIX_INNODB_MYISAM FAILS
245+
# Wait to ensure that drop temporary tables events
246+
# are present in binary log.
247+
--let $event_sequence= (Anonymous_)?Gtid # !Q(DROP.*TEMPORARY.*) # (Anonymous_)?Gtid # !Q(DROP.*TEMPORARY.*)
248+
--let $limit= 0,4
249+
--let $wait_for_binlog_events= 1
250+
--source include/assert_binlog_events.inc
240251
select get_lock("lock1",60);
241252
source include/show_binlog_events.inc;
242253
do release_lock("lock1");

mysql-test/include/assert_binlog_events.inc

+4-1
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,9 @@
116116
# the expected events. The timeout is given by $slave_timeout.
117117
#
118118
# $slave_timeout
119-
# Timeout used if $wait_for_binlog_events is enabled.
119+
# Default timeout used if $wait_for_binlog_events is enabled.
120+
# The default timeout is 300 seconds. You can change the timeout by
121+
# setting $slave_timeout. The unit for time is seconds.
120122
#
121123
# $rpl_debug
122124
# Print lots of debug info.
@@ -171,6 +173,7 @@ if ($wait_for_binlog_events)
171173
{
172174
--let $_abe_counter= 0
173175
--let $_abe_timeout= $slave_timeout
176+
# Wait 300 seconds for binlog events
174177
if (!$_abe_timeout)
175178
{
176179
--let $_abe_timeout= 300

mysql-test/suite/binlog/r/binlog_row_mix_innodb_myisam.result

+2
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,8 @@ insert into t0 select GET_LOCK("lock1",null);
260260
set autocommit=0;
261261
create table t2 (n int) engine=innodb;
262262
insert into t2 values (3);
263+
include/save_binlog_position.inc
264+
include/assert_binlog_events.inc [(Anonymous_)?Gtid # !Q(DROP.*TEMPORARY.*) # (Anonymous_)?Gtid # !Q(DROP.*TEMPORARY.*)]
263265
select get_lock("lock1",60);
264266
get_lock("lock1",60)
265267
1

mysql-test/suite/binlog/r/binlog_stm_mix_innodb_myisam.result

+2
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,8 @@ Note 1592 Unsafe statement written to the binary log using statement format sinc
252252
set autocommit=0;
253253
create table t2 (n int) engine=innodb;
254254
insert into t2 values (3);
255+
include/save_binlog_position.inc
256+
include/assert_binlog_events.inc [(Anonymous_)?Gtid # !Q(DROP.*TEMPORARY.*) # (Anonymous_)?Gtid # !Q(DROP.*TEMPORARY.*)]
255257
select get_lock("lock1",60);
256258
get_lock("lock1",60)
257259
1

0 commit comments

Comments
 (0)