Bug #46364 MyISAM transbuffer problems (NTM problem)
Submitted: 24 Jul 2009 12:26 Modified: 4 Aug 2010 23:20
Reporter: Lars Thalmann Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Replication Severity:S3 (Non-critical)
Version: OS:Any
Assigned to: Alfranio Tavares Correia Junior CPU Architecture:Any

[24 Jul 2009 12:26] Lars Thalmann
Description:
Mixing N (e.g. MyISAM) and T (e.g. InnoDB) statements in the same 
transaction can theoretically, in any implementation, cause one of 
two problems:

1. Recovery can't be done (N-changes not written to disk before commit)
2. Serializability is broken (N-changes written before T-changes in the log) 

This bug is about the potential of regression in the latest code.  

(See also BUG#28976.)

How to repeat:
CASE 1:
=======

create table foo (num_1 int);
create table foo2 (num_2 int, key foo2$num_2 (num_2)) engine=innodb;
insert into foo values (1);
insert into foo2 values (1),(2),(3);

connection 1                     connection 2
begin;
                                          begin;
update foo2 set num_2=12 where num_2=1;
                                          update foo2 set num_2=14 where num_2=3;
update foo set num_1=12;
                                          update foo set num_1=14;
                                          commit;
commit;

data on master:

mysql> select * from foo;
+-------+
| num_1 |
+-------+
|    14 |
+-------+

data on slave:

mysql> select * from foo;
+-------+
| num_1 |
+-------+
|    12 |
+-------+

CASE 2:
=======
create table t1 (a varchar(255));

connection 1                     connection 2

BEGIN
INSERT INTO t1 (a) VALUES
("Connection one");
                                 INSERT INTO t1 (a)
                                 VALEUS ("Connection two");

COMMIT

The transbuff is not used and the binlog is correct:

"Connection one"

"Connection two"

Suggested fix:
Several cases are described and each should be analyzed to ensure that the semantics have not changed in recent versions.

If the semantics has changed, then an option may be introduced to get the old behavior back.
[24 Jul 2009 12:28] Lars Thalmann
CASE 3:
=======
connection open;
begin # transactions starts when connections opens
...bunch of sql denpending on what function it in
UPDATE configuration SET last_contact_id = last_insert_id(last_contact_id + 1);
INSERT INTO contacts with c_id = id above grabbed from last_insert_id()
more insert/updates into other tables
UPDATE configuration SET last_incident_id = last_insert_id(last_incident_id + 1);
UPDATE configuration SET last_ref_no_id = if(date(incident_date) >= CURRENT_DATE, last_insert_id(last_ref_no_id+1), last_insert_id(0)), incident_date = @incident_date:=greatest(CURRENT_DATE, incident_date);
INSERT INTO incicdents with i_id = id above grabbed from last_insert_id() and ref_no frabled from the second statement.
more inserts/updates into other table.
Commit;
connect close

Basically there could 200 updates to the configuration table in one transactions and there could be hundreds of other users trying to increment these at the same time. We don't commit mid transaction. So someone sends us an API call we either commit the entire thing or we don't.
Each function can make a call to increment some counters in the configuration table at any point and it does this as needed.
[5 Aug 2009 10:13] Lars Thalmann
Alfranio has analyzed case 1-3, and the semantics of this has 
not changed for the last 2 years.  So, this is not a regression.
[3 Nov 2009 22:25] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/89228

3160 Alfranio Correia	2009-11-03
      BUG#46364 MyISAM transbuffer problems (NTM problem)
      
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables in statement and mixed modes.
      
      In a nutshell, the current code-base tries to preserve causality among the
      statements by not writing non-transactional statements directly to the
      binary log. Unfortunately, modifications done to non-transactional tables
      on behalf of a transaction become immediately visible to other connections
      but may not immediately get into the binary log and therefore consistency
      may be broken.
      
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a Pryor all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
      
      So, in this patch we introduce the option "ignore-causality" that can be
      used to bypass the current behavior in order to write directly to binary
      log statements that change non-transactional tables.
[23 Nov 2009 22:57] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/91363

3217 Alfranio Correia	2009-11-23
      BUG#46364 MyISAM transbuffer problems (NTM problem)
      
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables in statement and mixed modes.
      
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
      
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
      
      So, in this patch we introduce the option
          - "--binlog-direct-non-transactional-updates" that can be used to bypass
          the current behavior in order to write directly to binary log statements
          that change non-transactional tables.
     @ mysql-test/extra/rpl_tests/rpl_mixing_engines.inc
        Backported this from Celosia to improve the test cases related to the NTM issue.
     @ sql/log.cc
        Checks the --binlog-direct-non-transactional-updates before choosing
        to either use the trxn-cache or not.
     @ sql/mysqld.cc
        Introduces the option --binlog-direct-non-transactional-updates.
     @ sql/set_var.cc
        Introduces the option --binlog-direct-non-transactional-updates.
     @ sql/sql_class.h
        Introduces the option --binlog-direct-non-transactional-updates.
[19 Dec 2009 14:45] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/95104

3128 Alfranio Correia	2009-12-19
      BUG#46364 MyISAM transbuffer problems (NTM problem)
      
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables.
            
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
            
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
            
      So, in this patch we introduce the option
      - "--binlog-direct-non-transactional-updates" that can be used to bypass
      the current behavior in order to write directly to binary log statements
      that change non-transactional tables.
[19 Jan 2010 17:21] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/97424

3132 Alfranio Correia	2010-01-19
      BUG#46364 MyISAM transbuffer problems (NTM problem)
      
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables.
            
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
            
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
            
      So, in this patch we introduce the option
      - "--binlog-direct-non-transactional-updates" that can be used to bypass
      the current behavior in order to write directly to binary log statements
      that change non-transactional tables.
     @ mysql-test/extra/rpl_tests/rpl_binlog_max_cache_size.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/extra/rpl_tests/rpl_implicit_commit_binlog.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache. It also fixes comments.
     @ mysql-test/extra/rpl_tests/rpl_mixing_engines.test
        The STMT mode is unsafe when mixed-statements are executed thus making slaves to go out of sync. For that reason, it checks consistency if not in STMT mode.
     @ mysql-test/include/default_mysqld.cnf
        Makes binlog-direct-non-transactional-updates "TRUE" by default in the test cases.
     @ mysql-test/suite/binlog/r/binlog_multi_engine.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/binlog/r/binlog_switch_inside_trans.result
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        within a transaction or a procedure/function/trigger.
     @ mysql-test/suite/binlog/t/binlog_stm_mix_innodb_myisam-master.opt
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/binlog/t/binlog_switch_inside_trans.test
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        withing a transaction or a procedure/function/trigger.
     @ mysql-test/suite/ndb/r/ndb_binlog_format.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_begin_commit_rollback.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_concurrency_error.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_mixed_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_binlog_max_cache_size.result
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/suite/rpl/r/rpl_stm_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_start_stop_slave.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_stm_stop_middle_group.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_begin_commit_rollback.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_start_stop_slave.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_stop_middle_group.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ sql/log.cc
        Verifies if changes should be written to either the trx-cache or non-trx-cache through
        the use of the function use_trans_cache(). It also organizes the code.
     @ sql/log.h
        Changes the signature of some functions by adding the modifier "const" to the thd parameter.
        Specifically, the following functions are changed: 
        
        bool trans_has_updated_trans_table(const THD* thd);
        bool stmt_has_updated_trans_table(const THD *thd);
        bool use_trans_cache(const THD*, bool is_transactional);
     @ sql/mysqld.cc
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/set_var.cc
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/set_var.h
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/share/errmsg.txt
        Creates error messages to report when an user tries to change the new option binlog_direct_non_transactional_updates within a transaction or a procedure/
        function/trigger.
     @ sql/sql_class.h
        Adds the new option binlog_direct_non_transactional_updates.
[20 Jan 2010 16:09] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/97620

3132 Alfranio Correia	2010-01-20
      BUG#46364 MyISAM transbuffer problems (NTM problem)
      
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables.
            
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
            
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
            
      So, in this patch we introduce the option
      - "--binlog-direct-non-transactional-updates" that can be used to bypass
      the current behavior in order to write directly to binary log statements
      that change non-transactional tables.
     @ mysql-test/extra/rpl_tests/rpl_binlog_max_cache_size.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/extra/rpl_tests/rpl_implicit_commit_binlog.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache. It also fixes comments.
     @ mysql-test/extra/rpl_tests/rpl_mixing_engines.test
        The STMT mode is unsafe when mixed-statements are executed thus making slaves to go out of sync. For that reason, it checks consistency if not in STMT mode.
     @ mysql-test/include/default_mysqld.cnf
        Makes binlog-direct-non-transactional-updates "TRUE" by default in the test cases.
     @ mysql-test/suite/binlog/r/binlog_multi_engine.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/binlog/r/binlog_switch_inside_trans.result
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        within a transaction or a procedure/function/trigger.
     @ mysql-test/suite/binlog/t/binlog_stm_mix_innodb_myisam-master.opt
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/binlog/t/binlog_switch_inside_trans.test
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        withing a transaction or a procedure/function/trigger.
     @ mysql-test/suite/ndb/r/ndb_binlog_format.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_begin_commit_rollback.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_concurrency_error.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_mixed_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_binlog_max_cache_size.result
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/suite/rpl/r/rpl_stm_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_start_stop_slave.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_stm_stop_middle_group.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_begin_commit_rollback.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_start_stop_slave.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_stop_middle_group.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ sql/log.cc
        Verifies if changes should be written to either the trx-cache or non-trx-cache through the use of the function use_trans_cache(). It also organizes the code.
     @ sql/log.h
        Changes the signature of some functions by adding the modifier "const" to the thd parameter. Specifically, the following functions are changed: 
        
        bool trans_has_updated_trans_table(const THD* thd);
        bool stmt_has_updated_trans_table(const THD *thd);
        bool use_trans_cache(const THD*, bool is_transactional);
     @ sql/mysqld.cc
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/set_var.cc
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/set_var.h
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/share/errmsg.txt
        Creates error messages to report when an user tries to change the new option binlog_direct_non_transactional_updates within a transaction or a procedure/
        function/trigger.
     @ sql/sql_class.h
        Adds the new option binlog_direct_non_transactional_updates.
     @ support-files/my-small.cnf.sh
        Adds binlog-direct-non-transactional-updates to the example file. By default
        the option is disabled.
[20 Jan 2010 16:25] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/97622

3326 Alfranio Correia	2010-01-20
      BUG#46364 MyISAM transbuffer problems (NTM problem)
      
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables in statement and mixed modes.
      
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
      
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
      
      So, in this patch we introduce the option
          - "--binlog-direct-non-transactional-updates" that can be used to bypass
          the current behavior in order to write directly to binary log statements
          that change non-transactional tables.
     @ mysql-test/extra/rpl_tests/rpl_mixing_engines.inc
        Backported this from Celosia to improve the test cases related to the NTM issue.
     @ sql/log.cc
        Checks the --binlog-direct-non-transactional-updates before choosing
        to either use the trxn-cache or not.
     @ sql/mysqld.cc
        Introduces the option --binlog-direct-non-transactional-updates.
     @ sql/set_var.cc
        Introduces the option --binlog-direct-non-transactional-updates.
     @ sql/sql_class.h
        Introduces the option --binlog-direct-non-transactional-updates.
[20 Jan 2010 19:09] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/97643

3326 Alfranio Correia	2010-01-20
      BUG#46364 MyISAM transbuffer problems (NTM problem)
      
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables in statement and mixed modes.
      
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
      
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
      
      So, in this patch we introduce the option
          - "--binlog-direct-non-transactional-updates" that can be used to bypass
          the current behavior in order to write directly to binary log statements
          that change non-transactional tables.
     @ mysql-test/extra/rpl_tests/rpl_mixing_engines.inc
        Backported this from Celosia to improve the test cases related to the NTM issue.
     @ sql/log.cc
        Checks the --binlog-direct-non-transactional-updates before choosing
        to either use the trxn-cache or not.
     @ sql/mysqld.cc
        Introduces the option --binlog-direct-non-transactional-updates.
     @ sql/set_var.cc
        Introduces the option --binlog-direct-non-transactional-updates.
     @ sql/sql_class.h
        Introduces the option --binlog-direct-non-transactional-updates.
[20 Jan 2010 19:32] Alfranio Tavares Correia Junior
Pushed to 5.1-bugteam and pe.
[20 Jan 2010 23:47] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/97667

2970 Alfranio Correia	2010-01-20
      BUG#46364 MyISAM transbuffer problems (NTM problem)
            
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables.
                          
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
                  
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
                  
      So, in this patch we introduce the option
            - "--binlog-direct-non-transactional-updates" that can be used to bypass
            the current behavior in order to write directly to binary log statements
            that change non-transactional tables.
      
      Besides, it is used to enable the WL#2687 which is disabled by default.
     @ mysql-test/extra/rpl_tests/rpl_binlog_max_cache_size.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/extra/rpl_tests/rpl_implicit_commit_binlog.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache. It also fixes comments.
     @ mysql-test/extra/rpl_tests/rpl_mixing_engines.test
        The STMT mode is unsafe when mixed-statements are executed thus making slaves to go out of sync. For that reason, it checks consistency if not in STMT mode.
     @ mysql-test/include/default_mysqld.cnf
        Makes binlog-direct-non-transactional-updates "TRUE" by default in the test
        cases.
     @ mysql-test/r/mysqld--help-notwin.result
        Updates the result file with the new option.
     @ mysql-test/r/mysqld--help-win.result
        Updates the result file with the new option.
     @ mysql-test/suite/binlog/r/binlog_multi_engine.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/binlog/r/binlog_switch_inside_trans.result
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        within a transaction or a procedure/function/trigger.
     @ mysql-test/suite/binlog/t/binlog_stm_mix_innodb_myisam-master.opt
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing
        the test case and its result file.
     @ mysql-test/suite/binlog/t/binlog_switch_inside_trans.test
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        within a transaction or a procedure/function/trigger.
     @ mysql-test/suite/ndb/r/ndb_binlog_format.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_begin_commit_rollback.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_concurrency_error.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction
     @ mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_mixed_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_binlog_max_cache_size.result
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/suite/rpl/r/rpl_stm_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_start_stop_slave.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_stm_stop_middle_group.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_begin_commit_rollback.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_start_stop_slave.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_stop_middle_group.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ sql/log.cc
        Verifies if changes should be written to either the trx-cache or non-trx-cache through the use of the function use_trans_cache(). It also organizes the code.
     @ sql/log.h
        Changes the signature of some functions by adding the modifier "const" to the thd parameter. Specifically, the following functions are changed: 
                bool trans_has_updated_trans_table(const THD* thd);
                bool stmt_has_updated_trans_table(const THD *thd);
                bool use_trans_cache(const THD*, bool is_transactional);
     @ sql/share/errmsg-utf8.txt
        Creates error messages to report when an user tries to change the new option
        binlog_direct_non_transactional_updates within a transaction or a procedure/
        function/trigger.
     @ sql/share/errmsg.txt
        Creates error messages to report when an user tries to change the new option
        binlog_direct_non_transactional_updates within a transaction or a procedure/
        function/trigger.
     @ sql/sql_class.h
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/sys_vars.cc
        Adds the new option binlog_direct_non_transactional_updates.
     @ support-files/my-small.cnf.sh
        Adds binlog-direct-non-transactional-updates to the example file. By default
        the option is disabled.
[21 Jan 2010 13:11] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/97727

2971 Alfranio Correia	2010-01-21
      BUG#46364 MyISAM transbuffer problems (NTM problem)
            
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables.
                          
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
                  
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
                  
      So, in this patch we introduce the option
            - "--binlog-direct-non-transactional-updates" that can be used to bypass
            the current behavior in order to write directly to binary log statements
            that change non-transactional tables.
      
      Besides, it is used to enable the WL#2687 which is disabled by default.
     @ mysql-test/extra/rpl_tests/rpl_binlog_max_cache_size.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/extra/rpl_tests/rpl_implicit_commit_binlog.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache. It also fixes comments.
     @ mysql-test/extra/rpl_tests/rpl_mixing_engines.test
        The STMT mode is unsafe when mixed-statements are executed thus making slaves to go out of sync. For that reason, it checks consistency if not in STMT mode.
     @ mysql-test/include/default_mysqld.cnf
        Makes binlog-direct-non-transactional-updates "TRUE" by default in the test
        cases.
     @ mysql-test/r/mysqld--help-notwin.result
        Updates the result file with the new option.
     @ mysql-test/r/mysqld--help-win.result
        Updates the result file with the new option.
     @ mysql-test/suite/binlog/r/binlog_multi_engine.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/binlog/r/binlog_switch_inside_trans.result
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        within a transaction or a procedure/function/trigger.
     @ mysql-test/suite/binlog/t/binlog_stm_mix_innodb_myisam-master.opt
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing
        the test case and its result file.
     @ mysql-test/suite/binlog/t/binlog_switch_inside_trans.test
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        within a transaction or a procedure/function/trigger.
     @ mysql-test/suite/ndb/r/ndb_binlog_format.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_begin_commit_rollback.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_concurrency_error.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction
     @ mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_mixed_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_binlog_max_cache_size.result
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/suite/rpl/r/rpl_stm_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_start_stop_slave.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_stm_stop_middle_group.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_begin_commit_rollback.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_start_stop_slave.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_stop_middle_group.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ sql/log.cc
        Verifies if changes should be written to either the trx-cache or non-trx-cache through the use of the function use_trans_cache(). It also organizes the code.
     @ sql/log.h
        Changes the signature of some functions by adding the modifier "const" to the thd parameter. Specifically, the following functions are changed: 
                bool trans_has_updated_trans_table(const THD* thd);
                bool stmt_has_updated_trans_table(const THD *thd);
                bool use_trans_cache(const THD*, bool is_transactional);
     @ sql/share/errmsg-utf8.txt
        Creates error messages to report when an user tries to change the new option
        binlog_direct_non_transactional_updates within a transaction or a procedure/
        function/trigger.
     @ sql/share/errmsg.txt
        Creates error messages to report when an user tries to change the new option
        binlog_direct_non_transactional_updates within a transaction or a procedure/
        function/trigger.
     @ sql/sql_class.h
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/sys_vars.cc
        Adds the new option binlog_direct_non_transactional_updates.
     @ support-files/my-small.cnf.sh
        Adds binlog-direct-non-transactional-updates to the example file. By default
        the option is disabled.
[21 Jan 2010 21:06] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/97775

2971 Alfranio Correia	2010-01-21 [merge]
      BUG#46364 MyISAM transbuffer problems (NTM problem)
            
      It is well-known that due to concurrency issues, a slave can become
      inconsistent when a transaction contains updates to both transaction and
      non-transactional tables.
                          
      In a nutshell, the current code-base tries to preserve causality among the
      statements by writing non-transactional statements to the txn-cache which
      is flushed upon commit. However, modifications done to non-transactional
      tables on behalf of a transaction become immediately visible to other
      connections but may not immediately get into the binary log and therefore
      consistency may be broken.
                  
      In general, it is impossible to automatically detect causality/dependency
      among statements by just analyzing the statements sent to the server. This
      happen because dependency may be hidden in the application code and it is
      necessary to know a priori all the statements processed in the context of
      a transaction such as in a procedure. Moreover, even for the few cases that
      we could automatically address in the server, the computation effort
      required could make the approach infeasible.
                  
      So, in this patch we introduce the option
            - "--binlog-direct-non-transactional-updates" that can be used to bypass
            the current behavior in order to write directly to binary log statements
            that change non-transactional tables.
      
      Besides, it is used to enable the WL#2687 which is disabled by default.
     @ mysql-test/extra/rpl_tests/rpl_binlog_max_cache_size.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/extra/rpl_tests/rpl_implicit_commit_binlog.test
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache. It also fixes comments.
     @ mysql-test/extra/rpl_tests/rpl_mixing_engines.test
        The STMT mode is unsafe when mixed-statements are executed thus making slaves to go out of sync. For that reason, it checks consistency if not in STMT mode.
     @ mysql-test/include/default_mysqld.cnf
        Makes binlog-direct-non-transactional-updates "TRUE" by default in the test
        cases.
     @ mysql-test/r/mysqld--help-notwin.result
        Updates the result file with the new option.
     @ mysql-test/r/mysqld--help-win.result
        Updates the result file with the new option.
     @ mysql-test/suite/binlog/r/binlog_multi_engine.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/binlog/r/binlog_switch_inside_trans.result
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        within a transaction or a procedure/function/trigger.
     @ mysql-test/suite/binlog/t/binlog_stm_mix_innodb_myisam-master.opt
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing
        the test case and its result file.
     @ mysql-test/suite/binlog/t/binlog_switch_inside_trans.test
        Verifies if the user cannot change the opion binlog_direct_non_transactional_updates
        within a transaction or a procedure/function/trigger.
     @ mysql-test/suite/ndb/r/ndb_binlog_format.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_begin_commit_rollback.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_concurrency_error.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction
     @ mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_mixed_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_binlog_max_cache_size.result
        Changes the result set as the STMT mode behaves as both the ROW and MIXED modes and as such uses the non-trx-cache and takes longer to fill the trx-cache up and trigger an error.
     @ mysql-test/suite/rpl/r/rpl_stm_implicit_commit_binlog.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_mixing_engines.result
        Updates the result file because non-trx-changes are written ahead of the
        transaction.
     @ mysql-test/suite/rpl/r/rpl_stm_start_stop_slave.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/r/rpl_stm_stop_middle_group.result
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_begin_commit_rollback.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_start_stop_slave.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ mysql-test/suite/rpl/t/rpl_stm_stop_middle_group.test
        Sets binlog_direct_non_transactional_updates to FALSE in order to avoid changing the test case and its result file.
     @ sql/log.cc
        Verifies if changes should be written to either the trx-cache or non-trx-cache through the use of the function use_trans_cache(). It also organizes the code.
     @ sql/log.h
        Changes the signature of some functions by adding the modifier "const" to the thd parameter. Specifically, the following functions are changed: 
                bool trans_has_updated_trans_table(const THD* thd);
                bool stmt_has_updated_trans_table(const THD *thd);
                bool use_trans_cache(const THD*, bool is_transactional);
     @ sql/share/errmsg-utf8.txt
        Creates error messages to report when an user tries to change the new option
        binlog_direct_non_transactional_updates within a transaction or a procedure/
        function/trigger.
     @ sql/share/errmsg.txt
        Creates error messages to report when an user tries to change the new option
        binlog_direct_non_transactional_updates within a transaction or a procedure/
        function/trigger.
     @ sql/sql_class.h
        Adds the new option binlog_direct_non_transactional_updates.
     @ sql/sys_vars.cc
        Adds the new option binlog_direct_non_transactional_updates.
     @ support-files/my-small.cnf.sh
        Adds binlog-direct-non-transactional-updates to the example file. By default
        the option is disabled.
[21 Jan 2010 22:12] Alfranio Tavares Correia Junior
Pushed next-mr-bugfixing and 6.0-codebase-bugfixing.
[2 Feb 2010 7:57] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/98887

2987 Alexander Nozdrin	2010-02-02
      Manual merge of patch for Bug#46364 from mysql-next-mr-bugfixing.
      Conflicts:
        - mysql-test/r/mysqld--help-win.result
        - sql/sys_vars.cc
      
      Original revsion (in next-mr-bugfixing):
      ------------------------------------------------------------
      revno: 2971 [merge]
      revision-id: alfranio.correia@sun.com-20100121210527-rbuheu5rnsmcakh1
      committer: Alfranio Correia <alfranio.correia@sun.com>
      branch nick: mysql-next-mr-bugfixing
      timestamp: Thu 2010-01-21 21:05:27 +0000
      message:
        BUG#46364 MyISAM transbuffer problems (NTM problem)
              
        It is well-known that due to concurrency issues, a slave can become
        inconsistent when a transaction contains updates to both transaction and
        non-transactional tables.
                            
        In a nutshell, the current code-base tries to preserve causality among the
        statements by writing non-transactional statements to the txn-cache which
        is flushed upon commit. However, modifications done to non-transactional
        tables on behalf of a transaction become immediately visible to other
        connections but may not immediately get into the binary log and therefore
        consistency may be broken.
                    
        In general, it is impossible to automatically detect causality/dependency
        among statements by just analyzing the statements sent to the server. This
        happen because dependency may be hidden in the application code and it is
        necessary to know a priori all the statements processed in the context of
        a transaction such as in a procedure. Moreover, even for the few cases that
        we could automatically address in the server, the computation effort
        required could make the approach infeasible.
                    
        So, in this patch we introduce the option
              - "--binlog-direct-non-transactional-updates" that can be used to bypass
              the current behavior in order to write directly to binary log statements
              that change non-transactional tables.
        
        Besides, it is used to enable the WL#2687 which is disabled by default.
          ------------------------------------------------------------
          revno: 2970.1.1
          revision-id: alfranio.correia@sun.com-20100121131034-183r4qdyld7an5a0
          parent: alik@sun.com-20100121083914-r9rz2myto3tkdya0
          committer: Alfranio Correia <alfranio.correia@sun.com>
          branch nick: mysql-next-mr-bugfixing
          timestamp: Thu 2010-01-21 13:10:34 +0000
          message:
            BUG#46364 MyISAM transbuffer problems (NTM problem)
                  
            It is well-known that due to concurrency issues, a slave can become
            inconsistent when a transaction contains updates to both transaction and
            non-transactional tables.
                                
            In a nutshell, the current code-base tries to preserve causality among the
            statements by writing non-transactional statements to the txn-cache which
            is flushed upon commit. However, modifications done to non-transactional
            tables on behalf of a transaction become immediately visible to other
            connections but may not immediately get into the binary log and therefore
            consistency may be broken.
                        
            In general, it is impossible to automatically detect causality/dependency
            among statements by just analyzing the statements sent to the server. This
            happen because dependency may be hidden in the application code and it is
            necessary to know a priori all the statements processed in the context of
            a transaction such as in a procedure. Moreover, even for the few cases that
            we could automatically address in the server, the computation effort
            required could make the approach infeasible.
                        
            So, in this patch we introduce the option
                  - "--binlog-direct-non-transactional-updates" that can be used to bypass
                  the current behavior in order to write directly to binary log statements
                  that change non-transactional tables.
            
            Besides, it is used to enable the WL#2687 which is disabled by default.
[4 Feb 2010 10:19] Bugs System
Pushed into 5.1.44 (revid:joro@sun.com-20100204101444-2j32mhqroo0iiio6) (version source revid:alfranio.correia@sun.com-20100120190816-mnvwa7h7xbwxt2f8) (merge vers: 5.1.43) (pib:16)
[5 Feb 2010 11:48] Bugs System
Pushed into mysql-next-mr (revid:alik@sun.com-20100204063540-9czpdmpixi3iw2yb) (version source revid:alik@sun.com-20100202075642-bqb1zy6tt6tmor3h) (pib:16)
[5 Feb 2010 11:54] Bugs System
Pushed into 6.0.14-alpha (revid:alik@sun.com-20100205113942-oqovjy0eoqbarn7i) (version source revid:alik@sun.com-20100204105539-5h6k0s1jxofqaait) (merge vers: 6.0.14-alpha) (pib:16)
[5 Feb 2010 12:00] Bugs System
Pushed into 5.5.2-m2 (revid:alik@sun.com-20100203172258-1n5dsotny40yufxw) (version source revid:alexey.kopytov@sun.com-20100123210923-lx4o1ettww9fdkqk) (merge vers: 5.5.2-m2) (pib:16)
[10 Feb 2010 3:48] Jon Stephens
Documented bugfix in the 5.1.44, 5.5.2, and 6.0.14 changelogs as follows:

        Introduced the --binlog-direct-non-transactional-updates server
        option. This causes updates using the statement-based logging
        format to tables using non-transactional engines to be written
        directly to the binary log, rather than to the transaction
        cache.

        Before using this option, be certain that you have no
        dependencies between transactional and non-transactional 
        tables. A statement that both selects from an InnoDB table 
        and inserts into a MyISAM table is an example of such a 
        dependency. For more information, see "Binary Log Options 
        and Variables".

Also updated the indicated section of the 5.1/5.5/6.0 Manual with additional info from Alfranio's changeset comments.

Closed.
[13 Feb 2010 8:37] Bugs System
Pushed into 6.0.14-alpha (revid:alik@sun.com-20100213083436-9pesg4h55w1mekxc) (version source revid:luis.soares@sun.com-20100211135109-t63avry9fqpgyh78) (merge vers: 6.0.14-alpha) (pib:16)
[13 Feb 2010 8:39] Bugs System
Pushed into mysql-next-mr (revid:alik@sun.com-20100213083327-cee4ao3jpg33eggv) (version source revid:luis.soares@sun.com-20100211135018-1f9dbghg0itszigo) (pib:16)
[13 Feb 2010 9:41] Jon Stephens
Already documented fix in the 6.0.14 changelog. Setting back to Closed.
[13 Feb 2010 9:43] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/100238

3166 Luis Soares	2010-02-13
      Fixes for BUG#46364 merge from mysql-5.1.
      
      BUG#46364 has two distinct patches, one for 5.1 and one for
      celosia. Since mysql-5.1-rep+2 is a 5.1 GA codebase tree with
      extra replication features that are on 5.5, we need to revert the
      patch from 5.1 and apply the patch pushed to 5.5.
      
      However, one cannot do this straightfoward because the patch
      pushed to 5.5 relies on features that only exist on 5.5 and not
      on a 5.1 GA codebase. So we actually need parts of the patch from
      5.1 and part of the patch from 5.5.
      
      We fix this by merging the cset from 5.5 and keeping the common
      parts of the 5.1 patch. The extra parts of the patchs from 5.1
      and 5.5 are removed. The merge was done by cherrypicking the 5.5
      cset so that the files added in mysql-5.1-rep+2 tree keep the
      same fileid (avoids file conflicts in future merges, when merging
      this tree to mysql-next-mr/trunk).
      
      cset used from 5.5 was:
      alik@sun.com-20100202075642-bqb1zy6tt6tmor3h
      
      command:
        bzr merge -c alik@sun.com-20100202075642-bqb1zy6tt6tmor3h
      
      Conflicts
      =========
        Text conflict in mysql-test/include/default_mysqld.cnf
        Text conflict in sql/log.cc
        Contents conflict in sql/share/errmsg-utf8.txt
        Text conflict in sql/share/errmsg.txt
        Contents conflict in sql/sys_vars.cc
[17 Feb 2010 11:50] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/100606

3174 Luis Soares	2010-02-17 [merge]
      BUG#46364: Fix for binlog.binlog_switch_inside_trans test failure 
                 in mysql-5.1-rep+2.
      
      Merged Alfranio's post-merge fix.
[6 Mar 2010 11:02] Bugs System
Pushed into 5.5.3-m3 (revid:alik@sun.com-20100306103849-hha31z2enhh7jwt3) (version source revid:vvaintroub@mysql.com-20100213160132-nx1vlocxuta76txh) (merge vers: 5.5.99-m3) (pib:16)
[8 Mar 2010 19:55] Jon Stephens
Already documented in the 5.5.2 changelog.

Closed.
[12 Mar 2010 14:14] Bugs System
Pushed into 5.1.44-ndb-7.0.14 (revid:jonas@mysql.com-20100312135944-t0z8s1da2orvl66x) (version source revid:jonas@mysql.com-20100312115609-woou0te4a6s4ae9y) (merge vers: 5.1.44-ndb-7.0.14) (pib:16)
[12 Mar 2010 14:30] Bugs System
Pushed into 5.1.44-ndb-6.2.19 (revid:jonas@mysql.com-20100312134846-tuqhd9w3tv4xgl3d) (version source revid:jonas@mysql.com-20100312060623-mx6407w2vx76h3by) (merge vers: 5.1.44-ndb-6.2.19) (pib:16)
[12 Mar 2010 14:46] Bugs System
Pushed into 5.1.44-ndb-6.3.33 (revid:jonas@mysql.com-20100312135724-xcw8vw2lu3mijrhn) (version source revid:jonas@mysql.com-20100312103652-snkltsd197l7q2yg) (merge vers: 5.1.44-ndb-6.3.33) (pib:16)
[15 Mar 2010 4:43] Jon Stephens
No new changelog entries required. Closed.
[24 Mar 2010 8:15] Bugs System
Pushed into 6.0.14-alpha (revid:alik@sun.com-20100324081249-yfwol7qtcek6dh7w) (version source revid:alik@sun.com-20100324081113-kc7x1iytnplww91u) (merge vers: 6.0.14-alpha) (pib:16)
[24 Mar 2010 8:18] Bugs System
Pushed into mysql-next-mr (revid:alik@sun.com-20100324081159-5b8juv8ldiqwce8v) (version source revid:alik@sun.com-20100324081105-y72rautcea375zxm) (pib:16)
[24 Mar 2010 16:48] Paul DuBois
No new changelog entries required. Closed.
[27 Apr 2010 9:45] Bugs System
Pushed into 6.0.14-alpha (revid:alik@sun.com-20100427094135-5s49ecp3ckson6e2) (version source revid:alik@sun.com-20100427093843-uekr85qkd7orx12t) (merge vers: 6.0.14-alpha) (pib:16)
[27 Apr 2010 9:47] Bugs System
Pushed into 5.5.5-m3 (revid:alik@sun.com-20100427093804-a2k3rrjpwu5jegu8) (version source revid:alik@sun.com-20100427093804-a2k3rrjpwu5jegu8) (merge vers: 5.5.5-m3) (pib:16)
[27 Apr 2010 9:50] Bugs System
Pushed into mysql-next-mr (revid:alik@sun.com-20100427094036-38frbg3famdlvjup) (version source revid:alik@sun.com-20100427093825-92wc8b22d4yg34ju) (pib:16)
[27 Apr 2010 15:01] Jon Stephens
No new changelog entries required. Returning to Closed state.
[4 Aug 2010 8:08] Bugs System
Pushed into mysql-trunk 5.6.1-m4 (revid:alik@ibmvm-20100804080001-bny5271e65xo34ig) (version source revid:alik@sun.com-20100324081105-y72rautcea375zxm) (merge vers: 5.6.99-m4) (pib:18)
[4 Aug 2010 8:23] Bugs System
Pushed into mysql-trunk 5.6.1-m4 (revid:alik@ibmvm-20100804081533-c1d3rbipo9e8rt1s) (version source revid:alik@sun.com-20100324081105-y72rautcea375zxm) (merge vers: 5.6.99-m4) (pib:18)