done in previous patches.
There is an error in the Sun CC compiler that treats parameters that
differ in only qualifier as different, even though this is not
allowed by the standard (ISO/IEC 14882:2003, Section 13.1).
sql/log_event.cc:
Removing const qualifier since it causes linker error.
sql/log_event.h:
Restoring time_t instead of my_time_t since it causes warnings
elsewhere. Renaming parameters to functions since they hide
member variable (which causes warnings on Sun CC).
sql/rpl_record.cc:
Removing const qualifier since it causes linker error.
sql/rpl_rli.cc:
Restoring time_t instead of my_time_t since it causes warnings
elsewhere. Removing const qualifier since it causes linker error.
sql/rpl_rli.h:
Restoring time_t instead of my_time_t since it causes warnings
elsewhere. Removing const qualifier since it causes linker error.
done in previous patches.
There is an error in the Sun CC compiler that treats parameters that
differ in only qualifier as different, even though this is not
allowed by the standard (ISO/IEC 14882:2003, Section 13.1).
sql/rpl_rli.cc:
Changing signature for stmt_done() to use my_time_t instead of time_t.
sql/rpl_rli.h:
Changing signature for stmt_done() to use my_time_t instead of time_t.
Changing last_master_timestamp to use my_time_t instead of time_t.
skipped):
By moving statement end actions from Rows_log_event::do_apply_event() to
Rows_log_event::do_update_pos() they will always be executed, even if
Rows_log_event::do_apply_event() is skipped because the event originated
at the same server. This because Rows_log_event::do_update_pos() is always
executed (unless Rows_log_event::do_apply_event() failed with an error,
in which case the slave stops with an error anyway).
Adding test case.
Fixing logic to detect if inside a group. If a rotate event occured
when an initial prefix of events for a statement, but for which the
table did contain a key, last_event_start_time is set to zero, causing
rotate to end the group but without unlocking any tables. This left a
lock hanging around, which subsequently triggered an assertion when a
second attempt was made to lock the same sequence of tables.
In order to solve the above problem, a new flag was added to the relay
log info structure that is used to indicate that the replication thread
is currently executing a statement. Using this flag, the replication
thread is in a group if it is either in a statement or inside a trans-
action.
The patch also eliminates some gratuitous header file inclusions that
were not needed (and caused compile errors) and replaced them with
forward definitions.
sql/item_func.cc:
Including definition of MASTER_INFO.
sql/log.cc:
Including definition of RELAY_LOG_INFO since it is used in the file.
sql/log_event.cc:
Moving statement end actions from Rows_log_event::do_apply_event() to
Rows_log_event::do_update_pos().
Factoring out code to update group positions and event positions into
relay log info structure.
---
Adding debugging printouts.
Fixing logic to detect if inside a group.
sql/log_event.h:
Adding Rows_log_event::do_update_pos().
sql/mysqld.cc:
Including definition of MASTER_INFO.
sql/repl_failsafe.cc:
Including definition of MASTER_INFO.
sql/rpl_mi.h:
Including definition of RELAY_LOG_INFO since it is used in the file.
sql/rpl_rli.cc:
Adding member function stmt_done() to do after-statement updates of the
relay log info structure.
sql/rpl_rli.h:
Adding member function stmt_done() to do after-statement updates of the
relay log info structure.
sql/set_var.cc:
Including definition of MASTER_INFO.
sql/slave.cc:
Adding debuging printouts.
sql/slave.h:
Removing inclusion definitions of MASTER_INFO and RELAY_LOG_INFO and
replacing them with forward declarations since the classes are not
used in the file. The gratuitous inclusion lead to compile errors in
the two classes above in files that used neither.
sql/sql_binlog.cc:
Including definition of RELAY_LOG_INFO since it is used in the file.
sql/sql_class.cc:
Including definition of RELAY_LOG_INFO since it is used in the file.
sql/sql_class.h:
Removing inclusion definitions of RELAY_LOG_INFO and replacing it
with forward declaration since the class is not used in the file.
The gratuitous inclusion lead to compile errors in the class above
in files didn't use the class.
sql/sql_insert.cc:
Including definition of MASTER_INFO.
sql/sql_repl.cc:
Including definition of MASTER_INFO.
mysql-test/r/rpl_ndb_circular_simplex.result:
New BitKeeper file ``mysql-test/r/rpl_ndb_circular_simplex.result''
mysql-test/t/rpl_ndb_circular_simplex.test:
New BitKeeper file ``mysql-test/t/rpl_ndb_circular_simplex.test''
skipped):
By moving statement end actions from Rows_log_event::do_apply_event() to
Rows_log_event::do_update_pos() they will always be executed, even if
Rows_log_event::do_apply_event() is skipped because the event originated
at the same server. This because Rows_log_event::do_update_pos() is always
executed (unless Rows_log_event::do_apply_event() failed with an error,
in which case the slave stops with an error anyway).
Adding test case.
Fixing logic to detect if inside a group. If a rotate event occured
when an initial prefix of events for a statement, but for which the
table did contain a key, last_event_start_time is set to zero, causing
rotate to end the group but without unlocking any tables. This left a
lock hanging around, which subsequently triggered an assertion when a
second attempt was made to lock the same sequence of tables.
In order to solve the above problem, a new flag was added to the relay
log info structure that is used to indicate that the replication thread
is currently executing a statement. Using this flag, the replication
thread is in a group if it is either in a statement or inside a trans-
action.
The patch also eliminates some gratuitous header file inclusions that
were not needed (and caused compile errors) and replaced them with
forward definitions.
into romeo.(none):/home/bk/b23171-mysql-5.1-new-rpl
mysql-test/r/rpl_row_tabledefs_2myisam.result:
Auto merged
mysql-test/r/rpl_row_tabledefs_3innodb.result:
Auto merged
sql/rpl_rli.cc:
Auto merged
sql/rpl_rli.h:
Auto merged
sql/rpl_utility.cc:
Auto merged
sql/rpl_utility.h:
Auto merged
sql/slave.h:
Auto merged
sql/log.cc:
Manual merge
sql/log_event.cc:
Manual merge
sql/log_event.h:
Manual merge
sql/slave.cc:
Manual merge
sql/sql_binlog.cc:
Manual merge
Tail fixes after re-applying patches to older version of clone.
sql/log_event.cc:
Name change of shall_skip() -> do_shall_skip()
Introducing public shall_skip().
Name change of skip reason enumeration constants.
Removing extreneous argument to slave_print_msg() causing compiler warning.
sql/log_event.h:
Adding enumeration for skip reason.
Factoring out exec_event() into exec_relay_log_event().
Making public interface to event execution primitives.
Adding documentation.
Making some (internal) functions const-correct.
sql/rpl_rli.cc:
replicate_same_server_id is now a member variable of RLI.
sql/rpl_rli.h:
replicate_same_server_id is now a member variable of RLI.
sql/slave.cc:
Using RLI-specific member variable replicate_same_server_id instead of
global instance.
Moving comments about skipping logic to exec_relay_log_event().
Moving event execution logic to exec_relay_log_event().
sql/sql_binlog.cc:
Using apply_event() directly and adding comment with explenation.
Adding code to release allocated memory when tables_to_lock list is
cleared.
sql/log_event.cc:
Using RPL_TABLE_LIST instead of TABLE_LIST for tables_to_lock.
sql/rpl_rli.cc:
Moving st_relay_log_info::clear_tables_to_lock() into rpl_rli.cc.
Adding code to release memory allocated for saved table definition.
sql/rpl_rli.h:
Moving st_relay_log_info::clear_tables_to_lock() into rpl_rli.cc.
Using RPL_TABLE_LIST instead of TABLE_LIST for tables_to_lock.
sql/rpl_utility.h:
Adding forward declarations.
Adding boolean to tell if tabledef is valid.
Third patch of the bug fix where the code for skipping events and for
executing events is factored out into three functions:
- shall_skip() to decide if the event shall be skipped and the
reason for it;
- do_apply_event(), where the event is applied to the database; and
- do_update_pos(), which updates the actual relay log position and
group positions.
mysql-test/r/rpl_row_tabledefs_2myisam.result:
Result change.
mysql-test/r/rpl_row_tabledefs_3innodb.result:
Result change.
sql/log_event.cc:
Creating shall_skip(), do_update_pos(), and do_apply_event()
functions for each event by factoring out the previous code.
Adding debug code and fixing some error codes that were not correct.
sql/rpl_rli.cc:
Renaming unsafe_to_stop_at into last_event_start_time.
Adding debug code.
sql/rpl_rli.h:
Renaming unsafe_to_stop_at into last_event_start_time.
sql/slave.cc:
Renaming unsafe_to_stop_at into last_event_start_time.
Third patch of the bug fix where the code for skipping events and for
executing events is factored out into three functions:
- shall_skip() to decide if the event shall be skipped and the
reason for it;
- do_apply_event(), where the event is applied to the database; and
- do_update_pos(), which updates the actual relay log position and
group positions.
Changed header to GPL version 2 only
client/mysqlslap.c:
Changed header to GPL version 2 only
include/atomic/nolock.h:
Changed header to GPL version 2 only
include/atomic/rwlock.h:
Changed header to GPL version 2 only
include/atomic/x86-gcc.h:
Changed header to GPL version 2 only
include/atomic/x86-msvc.h:
Changed header to GPL version 2 only
include/my_atomic.h:
Changed header to GPL version 2 only
include/my_trie.h:
Changed header to GPL version 2 only
include/my_vle.h:
Changed header to GPL version 2 only
include/mysql/plugin.h:
Changed header to GPL version 2 only
mysys/my_atomic.c:
Changed header to GPL version 2 only
mysys/my_getncpus.c:
Changed header to GPL version 2 only
mysys/my_memmem.c:
Changed header to GPL version 2 only
mysys/my_vle.c:
Changed header to GPL version 2 only
mysys/trie.c:
Changed header to GPL version 2 only
plugin/Makefile.am:
Changed header to GPL version 2 only
server-tools/instance-manager/IMService.h:
Changed header to GPL version 2 only
server-tools/instance-manager/WindowsService.h:
Changed header to GPL version 2 only
server-tools/instance-manager/exit_codes.h:
Changed header to GPL version 2 only
server-tools/instance-manager/user_management_commands.h:
Changed header to GPL version 2 only
sql/authors.h:
Changed header to GPL version 2 only
sql/contributors.h:
Changed header to GPL version 2 only
sql/event_data_objects.cc:
Changed header to GPL version 2 only
sql/event_data_objects.h:
Changed header to GPL version 2 only
sql/event_db_repository.cc:
Changed header to GPL version 2 only
sql/event_db_repository.h:
Changed header to GPL version 2 only
sql/event_queue.cc:
Changed header to GPL version 2 only
sql/event_queue.h:
Changed header to GPL version 2 only
sql/event_scheduler.cc:
Changed header to GPL version 2 only
sql/event_scheduler.h:
Changed header to GPL version 2 only
sql/events.cc:
Changed header to GPL version 2 only
sql/events.h:
Changed header to GPL version 2 only
sql/ha_ndbcluster_binlog.cc:
Changed header to GPL version 2 only
sql/ha_ndbcluster_binlog.h:
Changed header to GPL version 2 only
sql/ha_ndbcluster_tables.h:
Changed header to GPL version 2 only
sql/ha_partition.cc:
Changed header to GPL version 2 only
sql/ha_partition.h:
Changed header to GPL version 2 only
sql/item_xmlfunc.cc:
Changed header to GPL version 2 only
sql/item_xmlfunc.h:
Changed header to GPL version 2 only
sql/log.h:
Changed header to GPL version 2 only
sql/partition_element.h:
Changed header to GPL version 2 only
sql/partition_info.cc:
Changed header to GPL version 2 only
sql/partition_info.h:
Changed header to GPL version 2 only
sql/rpl_filter.cc:
Changed header to GPL version 2 only
sql/rpl_filter.h:
Changed header to GPL version 2 only
sql/rpl_injector.cc:
Changed header to GPL version 2 only
sql/rpl_injector.h:
Changed header to GPL version 2 only
sql/rpl_mi.cc:
Changed header to GPL version 2 only
sql/rpl_mi.h:
Changed header to GPL version 2 only
sql/rpl_rli.cc:
Changed header to GPL version 2 only
sql/rpl_rli.h:
Changed header to GPL version 2 only
sql/rpl_tblmap.cc:
Changed header to GPL version 2 only
sql/rpl_tblmap.h:
Changed header to GPL version 2 only
sql/rpl_utility.cc:
Changed header to GPL version 2 only
sql/rpl_utility.h:
Changed header to GPL version 2 only
sql/sql_binlog.cc:
Changed header to GPL version 2 only
sql/sql_partition.cc:
Changed header to GPL version 2 only
sql/sql_partition.h:
Changed header to GPL version 2 only
sql/sql_plugin.cc:
Changed header to GPL version 2 only
sql/sql_plugin.h:
Changed header to GPL version 2 only
sql/sql_servers.cc:
Changed header to GPL version 2 only
sql/sql_servers.h:
Changed header to GPL version 2 only
sql/sql_tablespace.cc:
Changed header to GPL version 2 only
sql/sql_yacc.yy.bak:
Changed header to GPL version 2 only
storage/Makefile.am:
Changed header to GPL version 2 only
storage/archive/Makefile.am:
Changed header to GPL version 2 only
storage/blackhole/Makefile.am:
Changed header to GPL version 2 only
storage/csv/Makefile.am:
Changed header to GPL version 2 only
storage/example/Makefile.am:
Changed header to GPL version 2 only
storage/federated/Makefile.am:
Changed header to GPL version 2 only
storage/innobase/handler/Makefile.am:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/AllocNodeId.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/CreateFilegroup.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/CreateFilegroupImpl.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/CreateObj.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DictObjOp.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DihFragCount.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DropFilegroup.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DropFilegroupImpl.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DropObj.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/Extent.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/LgmanContinueB.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/PgmanContinueB.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/RestoreContinueB.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/RestoreImpl.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/RouteOrd.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/TsmanContinueB.hpp:
Changed header to GPL version 2 only
storage/ndb/include/ndbapi/NdbIndexStat.hpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/mgmapi_logevent/mgmapi_logevent.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/mgmapi_logevent_dual/mgmapi_logevent_dual.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_async/ndbapi_async.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_async1/ndbapi_async1.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_event/ndbapi_event.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_retries/ndbapi_retries.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_scan/ndbapi_scan.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_simple/ndbapi_simple.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_simple_dual/ndbapi_simple_dual.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_simple_index/ndbapi_simple_index.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbdih/printSysfile.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/DbtupDiskAlloc.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/DbtupVarAlloc.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/Undo_buffer.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/Undo_buffer.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/tuppage.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/tuppage.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtux/DbtuxStat.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/diskpage.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/lgman.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/lgman.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/pgman.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/pgman.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/print_file.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/record_types.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/restore.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/restore.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/tsman.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/tsman.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/DLCFifoList.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/DLCHashTable.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/DynArr256.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/DynArr256.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/KeyTable2Ref.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/LinearPool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/NdbdSuperPool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/NdbdSuperPool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/Pool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/Pool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/RWPool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/RWPool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/Rope.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/SLFifoList.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/WOPool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/WOPool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/bench_pool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/ndbd_malloc_impl.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/ndbd_malloc_impl.hpp:
Changed header to GPL version 2 only
storage/ndb/src/mgmsrv/ParamInfo.cpp:
Changed header to GPL version 2 only
storage/ndb/src/ndbapi/NdbIndexStat.cpp:
Changed header to GPL version 2 only
storage/ndb/test/ndbapi/testIndexStat.cpp:
Changed header to GPL version 2 only
storage/ndb/test/tools/listen.cpp:
Changed header to GPL version 2 only
storage/ndb/tools/restore/ndb_nodegroup_map.h:
Changed header to GPL version 2 only
strings/my_strchr.c:
Changed header to GPL version 2 only
unittest/mysys/base64-t.c:
Changed header to GPL version 2 only
unittest/mysys/bitmap-t.c:
Changed header to GPL version 2 only
unittest/mysys/my_atomic-t.c:
Changed header to GPL version 2 only
unittest/mytap/tap.c:
Changed header to GPL version 2 only
unittest/mytap/tap.h:
Changed header to GPL version 2 only
win/Makefile.am:
Changed header to GPL version 2 only
Second patch to fix skipping code. Moving relay and binary log
position changing code from do_apply_event [old exec_event()] into
do_update_pos() and doing other changes necessary to support that.
Fixing a bug that can cause deadlock if rotating binary log when committing
a changes to a transactional table that is not inside a transaction and
cause a rotate log.
sql/log.cc:
Changing condition in binlog_commit() to skip calling
binlog_end_trans() twice to match condition in binlog_end_trans().
sql/log_event.cc:
Name change: apply_event_impl() -> do_apply_event()
Name change: advance_coord_impl() -> do_update_pos()
do_apply_event() now uses pointer to constant RELAY_LOG_INFO to prevent
inadvertandly changing the position in the code. Doing this would make
the skipping code loose track of where it is. All position changing code
shall now be in do_update_pos().
Factoring out relay and binary log position updating code from
do_apply_event() [previously exec_event()] into do_update_pos().
Using a safe approach to make it work: will refine the refactoring
when the skipping code is implemented.
Adding const casts where needed.
Changing signature to use pointers to constant objects where needed.
sql/rpl_rli.cc:
Making cached_charset_compare() const to work with constant instances of RELAY_LOG_INFO.
Debriding code.
sql/rpl_rli.h:
Making cached_charset_compare() const to work with constant instances of RELAY_LOG_INFO.
Debriding code.
sql/rpl_utility.cc:
Using pointer to const RELAY_LOG_INFO to make it work with other code.
sql/rpl_utility.h:
Using pointer to const RELAY_LOG_INFO to make it work with other code.
sql/slave.cc:
Using pointer to const RELAY_LOG_INFO to make it work with other code.
Adding const cast where necessary.
sql/slave.h:
Using pointer to const RELAY_LOG_INFO to make it work with other code.
Second patch to fix skipping code. Moving relay and binary log
position changing code from do_apply_event [old exec_event()] into
do_update_pos() and doing other changes necessary to support that.
Fixing a bug that can cause deadlock if rotating binary log when committing
a changes to a transactional table that is not inside a transaction and
cause a rotate log.
Not replicating the mysql database *at all* any more. All changes to
mysql tables are replicated by replicating the statements that do
the changes.
mysql-test/r/rpl_do_grant.result:
Result change
mysql-test/t/rpl_do_grant.test:
Deleting grants on both master and server since the mysql
database is not replicated any more.
sql/handler.cc:
Removing code that selectively checks what tables in the mysql
database to ignore. The entire mysql database is not replicated
any more.
sql/log_event.cc:
Disabling code to reload grants and access when certain tables are
touched.
sql/rpl_rli.h:
Removing unused code.
sql/slave.cc:
Removing unused code.
sql/sql_class.cc:
Mysql queries (i.e., queries that affects tables in the mysql database)
are now replicated by statement instead of replicating the tables in
the mysql database.
make code easier to maintain.
sql/CMakeLists.txt:
New file
sql/Makefile.am:
New file
sql/rpl_rli.h:
Changed master_info into a class
sql/slave.cc:
Moved master info functionality into rpl_mi.cc
sql/slave.h:
Moved master info functionality into rpl_mi.cc
sql/rpl_mi.cc:
Moved master info functionality into rpl_mi.cc
sql/rpl_mi.h:
Moved master info functionality into rpl_mi.cc
should be a separate module (i.e. a class) to make it easier to maintain the
code, e.g. by having checks within the rli checking sanity of data and making
member variables private. This will also ease implementation of multi-source
and, at least in my fantasies :), make it possible in some future to have
separate replication servers.
sql/Makefile.am:
Added file rpl_rli.cc
sql/repl_failsafe.cc:
Move function
sql/rpl_rli.h:
moved functions
sql/slave.cc:
Moved rli code into rpl_rli.cc
sql/sql_repl.cc:
Changed function to be member function
sql/rpl_rli.cc:
Code for rli
should be a separate module (i.e. a class) to make it easier to maintain the
code, e.g. by having checks within the rli checking sanity of data and making
member variables private. This will also ease implementation of multi-source
and, at least in my fantasies :), make it possible in some future to have
separate replication servers.
into mysql.com:/home/cps/mysql/devel/5.1-logs-final
sql/ha_ndbcluster_binlog.cc:
Auto merged
sql/log.cc:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/mysqld.cc:
Auto merged
sql/rpl_rli.h:
Auto merged
sql/slave.cc:
Auto merged
test rpl_err_ignoredtables.
sql/log_event.cc:
Clearing tables to lock list in the event of errors.
Adding asserts to catch failing to clear the list of tables to lock.
Releasing allocated memory if the table will not be replicated.
sql/rpl_rli.h:
Adding assert to ensure post-condition of clear_tables_to_lock().
Minor rewrites.
sql/ha_ndbcluster_binlog.cc:
use MYSQL_BIN_LOG instead of MYSQL_LOG
sql/log.cc:
Split MYSQL_LOG into base MYSQL_LOG and
MYSQL_GENERAL_LOG, MYSQL_SLOW_LOG, MYSQL_BIN_LOG
sql/log.h:
Split MYSQL_LOG into base MYSQL_LOG and
MYSQL_GENERAL_LOG, MYSQL_SLOW_LOG, MYSQL_BIN_LOG
sql/log_event.h:
use MYSQL_BIN_LOG instead of MYSQL_LOG
sql/mysql_priv.h:
use MYSQL_BIN_LOG instead of MYSQL_LOG
sql/mysqld.cc:
fix appropriate comments: use MYSQL_BIN_LOG instead of MYSQL_LOG
sql/rpl_injector.cc:
use MYSQL_BIN_LOG instead of MYSQL_LOG
sql/rpl_injector.h:
use MYSQL_BIN_LOG instead of MYSQL_LOG
sql/rpl_rli.h:
use MYSQL_BIN_LOG instead of MYSQL_LOG
sql/slave.cc:
Fix appropriate comments: use MYSQL_BIN_LOG instead of MYSQL_LOG.
Fix usage of new_file(): now we don't need to pass locking-related
info to the function.
sql/slave.h:
Use MYSQL_BIN_LOG instead of MYSQL_LOG in appropriate comments
Table maps are now written on aquiring locks to tables and released
at the end of each logical statement.
mysql-test/extra/binlog_tests/ctype_cp932.test:
Disabling cleanup code
mysql-test/r/binlog_row_blackhole.result:
Result change
mysql-test/r/binlog_row_mix_innodb_myisam.result:
Result change
mysql-test/r/binlog_stm_ctype_cp932.result:
Result change
mysql-test/r/rpl_row_charset.result:
Result change
mysql-test/r/rpl_row_create_table.result:
Result change
mysql-test/t/rpl_row_create_table.test:
Binlog position change
sql/handler.cc:
Writing table map after external_lock()
sql/handler.h:
Adding class for table operation hooks.
sql/log.cc:
Adding binlog_write_table_map() to THD.
Removing write_table_map() from MYSQL_LOG.
sql/log.h:
Minor interface changes to move table map writing.
sql/log_event.cc:
Removing pre-allocation of memory for buffers.
Allowing ULONG_MAX as table id denoting an event to ignore (only used to transfer flags).
Adding code to collect tables while seeing table maps and lock collected tables
when seeing a binrow event.
Debriding code as a result of the above changes.
sql/log_event.h:
Minor interface changes.
sql/mysql_priv.h:
Adding hooks argument to create_table_from_items().
sql/parse_file.cc:
Minor fix to avoid crash in debug printout.
sql/rpl_rli.h:
Adding list of tables to lock to RLI structure.
sql/slave.cc:
Using list of tables to lock from RLI structure.
sql/sql_acl.cc:
Removing redundant pending events flush.
sql/sql_base.cc:
Moving pending event flush.
Using flag to guard to clear statement transaction only if this is the original
open tables state.
sql/sql_class.cc:
Adding flag for open tables state.
Removing redundant pending events flushes.
Write a dummy event to indicate that the tables to lock should be emptied
on the slave.
sql/sql_class.h:
Adding open tables state flags.
Adding binlog_write_table_map() function to THD.
Changes to select_create() to support new locking scheme.
sql/sql_insert.cc:
Adding rollback of statement transaction on error. It can now contain
events after locking tables.
sql/sql_load.cc:
Removing redundant pending event flush.
sql/sql_table.cc:
Adding hooks argument to create_table_from_items().
Calling prelock hook before starting to lock tables.
sql/sql_update.cc:
Removing a compiler warning.
sql/table.h:
Minor changes.