MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Alfranio Correia Date:August 28 2009 11:01am
Subject:bzr push into mysql-5.0-bugteam branch (alfranio.correia:2720 to 2721)
Bug#46861
View as plain text  
 2721 Alfranio Correia	2009-08-28
      Post-fix for BUG#46861.

    modified:
      mysql-test/r/rpl_rewrite_db.result
      mysql-test/t/rpl_rewrite_db.test
 2720 Alfranio Correia	2009-08-26
      BUG#46861 Auto-closing of temporary tables broken by replicate-rewrite-db
      
      When a connection is dropped any remaining temporary table is also automatically
      dropped and the SQL statement of this operation is written to the binary log in
      order to drop such tables on the slave and keep the slave in sync. Specifically,
      the current code base creates the following type of statement:
      DROP /*!40005 TEMPORARY */ TABLE IF EXISTS `db`.`table`;
      
      Unfortunately, appending the database to the table name in this manner circumvents
      the replicate-rewrite-db option (and any options that check the current database).
      To solve the issue, we started writing the statement to the binary as follows:
      use `db`; DROP /*!40005 TEMPORARY */ TABLE IF EXISTS `table`;

    modified:
      mysql-test/r/drop_temp_table.result
      mysql-test/r/mix_innodb_myisam_binlog.result
      mysql-test/r/rpl_drop_temp.result
      mysql-test/r/rpl_rewrite_db.result
      mysql-test/t/rpl_drop_temp.test
      mysql-test/t/rpl_rewrite_db-slave.opt
      mysql-test/t/rpl_rewrite_db.test
      sql/sql_base.cc
=== modified file 'mysql-test/r/rpl_rewrite_db.result'
--- a/mysql-test/r/rpl_rewrite_db.result	2009-08-26 14:50:30 +0000
+++ b/mysql-test/r/rpl_rewrite_db.result	2009-08-28 10:59:40 +0000
@@ -90,7 +90,12 @@ a	b
 2	row 2
 3	row 3
 0	
+set sql_log_bin= 0;
 drop database rewrite;
+set sql_log_bin= 1;
+set sql_log_bin= 0;
+drop table t1;
+set sql_log_bin= 1;
 
 ****
 **** Bug #46861 Auto-closing of temporary tables broken by replicate-rewrite-db
@@ -189,6 +194,7 @@ get_lock("con_03",10)
 1
 
 **** Checking the binary log and temporary tables
+
 show status like 'Slave_open_temp_tables';
 Variable_name	Value
 Slave_open_temp_tables	0

=== modified file 'mysql-test/t/rpl_rewrite_db.test'
--- a/mysql-test/t/rpl_rewrite_db.test	2009-08-26 14:50:30 +0000
+++ b/mysql-test/t/rpl_rewrite_db.test	2009-08-28 10:59:40 +0000
@@ -73,7 +73,14 @@ connection slave;
 # The empty line last comes from the end line field in the file
 select * from rewrite.t1;
 
+set sql_log_bin= 0;
 drop database rewrite;
+set sql_log_bin= 1;
+
+connection master;
+set sql_log_bin= 0;
+drop table t1;
+set sql_log_bin= 1;
 
 # End of 4.1 tests
 
@@ -197,7 +204,7 @@ select get_lock("con_03",10);
 
 --echo
 --echo **** Checking the binary log and temporary tables
---ehco
+--echo
 connection master;
 sync_slave_with_master;
 connection slave;


Attachment: [text/bzr-bundle] bzr/alfranio.correia@sun.com-20090828105940-r1i8ejkmcsj320uy.bundle
Thread
bzr push into mysql-5.0-bugteam branch (alfranio.correia:2720 to 2721)Bug#46861Alfranio Correia28 Aug