diff options
author | Alexey Kopytov <Alexey.Kopytov@Sun.com> | 2010-05-11 12:23:57 +0400 |
---|---|---|
committer | Alexey Kopytov <Alexey.Kopytov@Sun.com> | 2010-05-11 12:23:57 +0400 |
commit | c7fbc8c67c6739b900e19e0091b28adc11bd5d58 (patch) | |
tree | 703aceeb455a79b6ec6291bdc71ff13ffa24a2c0 /sql/log.cc | |
parent | 5ef2bdea81a68a5440235bb5c841fff5dcc2b2c7 (diff) | |
parent | df0b6707dabf49ed09e798c6ace1d860320ab11c (diff) | |
download | mariadb-git-c7fbc8c67c6739b900e19e0091b28adc11bd5d58.tar.gz |
Manual merge from mysql-5.1-bugteam to mysql-trunk-merge.
Text conflict in sql/log.cc
Text conflict in sql/log.h
Text conflict in sql/sql_class.cc
Text conflict in sql/sql_load.cc
Diffstat (limited to 'sql/log.cc')
-rw-r--r-- | sql/log.cc | 38 |
1 files changed, 1 insertions, 37 deletions
diff --git a/sql/log.cc b/sql/log.cc index 6ed8d5cb646..a80e054178f 100644 --- a/sql/log.cc +++ b/sql/log.cc @@ -1528,11 +1528,6 @@ binlog_flush_trx_cache(THD *thd, binlog_cache_mngr *cache_mngr, cache_mngr->trx_cache.has_incident()); cache_mngr->reset_cache(&cache_mngr->trx_cache); - /* - We need to step the table map version after writing the - transaction cache to disk. - */ - mysql_bin_log.update_table_map_version(); statistic_increment(binlog_cache_use, &LOCK_status); if (cache_log->disk_writes != 0) { @@ -1592,13 +1587,6 @@ binlog_truncate_trx_cache(THD *thd, binlog_cache_mngr *cache_mngr, bool all) else cache_mngr->trx_cache.restore_prev_position(); - /* - We need to step the table map version on a rollback to ensure that a new - table map event is generated instead of the one that was written to the - thrown-away transaction cache. - */ - mysql_bin_log.update_table_map_version(); - DBUG_ASSERT(thd->binlog_get_pending_rows_event(is_transactional) == NULL); DBUG_RETURN(error); } @@ -1650,11 +1638,6 @@ binlog_flush_stmt_cache(THD *thd, binlog_cache_mngr *cache_mngr) DBUG_RETURN(error); cache_mngr->reset_cache(&cache_mngr->stmt_cache); - /* - We need to step the table map version after writing the - transaction cache to disk. - */ - mysql_bin_log.update_table_map_version(); statistic_increment(binlog_cache_use, &LOCK_status); if (cache_log->disk_writes != 0) { @@ -2662,7 +2645,7 @@ const char *MYSQL_LOG::generate_name(const char *log_name, MYSQL_BIN_LOG::MYSQL_BIN_LOG(uint *sync_period) :bytes_written(0), prepared_xids(0), file_id(1), open_count(1), - need_start_event(TRUE), m_table_map_version(0), + need_start_event(TRUE), sync_period_ptr(sync_period), is_relay_log(0), signal_cnt(0), description_event_for_exec(0), description_event_for_queue(0) @@ -4447,7 +4430,6 @@ int THD::binlog_write_table_map(TABLE *table, bool is_transactional) DBUG_RETURN(error); binlog_table_maps++; - table->s->table_map_version= mysql_bin_log.table_map_version(); DBUG_RETURN(0); } @@ -4589,21 +4571,6 @@ MYSQL_BIN_LOG::flush_and_set_pending_rows_event(THD *thd, DBUG_RETURN(1); } - /* - We step the table map version if we are writing an event - representing the end of a statement. - - In an ideal world, we could avoid stepping the table map version, - since we could then reuse the table map that was written earlier - in the cache. This does not work since STMT_END_F implies closing - all table mappings on the slave side. - - TODO: Find a solution so that table maps does not have to be - written several times within a transaction. - */ - if (pending->get_flags(Rows_log_event::STMT_END_F)) - ++m_table_map_version; - delete pending; } @@ -4792,9 +4759,6 @@ unlock: } } - if (event_info->flags & LOG_EVENT_UPDATE_TABLE_MAP_VERSION_F) - ++m_table_map_version; - DBUG_RETURN(error); } |