Uncommited changes are replicated and stay on slave after
rollback on master

Making test slightly more generic and robust.

mysql-test/suite/rpl/t/rpl_trigger.test:
  Adding code to check that InnoDB is available on slave as well.
  Making code slightly more generic.
This commit is contained in:
Mats Kindahl 2008-12-05 10:23:27 +01:00
parent 43e9d5b3d5
commit 832770842e
2 changed files with 13 additions and 18 deletions

View file

@ -988,16 +988,9 @@ after insert on t1
for each row insert into log values ( new.f );
set autocommit = 0;
insert into t1 values ( 1 );
select * from t1;
f
1
select * from t1;
f
rollback;
Warnings:
Warning 1196 Some non-transactional changed tables couldn't be rolled back
select * from t1;
f
select * from t1;
f
Comparing tables master:test.t1 and slave:test.t1
Comparing tables master:test.log and slave:test.log
drop table t1, log;

View file

@ -480,8 +480,11 @@ sync_slave_with_master;
# rollback on master
#
connection master;
source include/master-slave-reset.inc;
source include/have_innodb.inc;
connection slave;
source include/have_innodb.inc;
connection master;
create table t1 ( f int ) engine = innodb;
@ -492,16 +495,15 @@ create trigger tr
set autocommit = 0;
insert into t1 values ( 1 );
select * from t1;
sync_slave_with_master;
select * from t1;
connection master;
rollback;
select * from t1;
sync_slave_with_master;
select * from t1;
let $diff_table_1=master:test.t1;
let $diff_table_2=slave:test.t1;
--source include/diff_tables.inc
let $diff_table_1=master:test.log;
let $diff_table_2=slave:test.log;
--source include/diff_tables.inc
connection master;
drop table t1, log;