diff options
author | unknown <serg@serg.mylan> | 2005-02-17 13:52:16 +0100 |
---|---|---|
committer | unknown <serg@serg.mylan> | 2005-02-17 13:52:16 +0100 |
commit | c5c497164fbc48bcc50770ced833a07788082aaf (patch) | |
tree | b920a7ed5633935af693da76909cc6f626123729 /sql/log_event.h | |
parent | 98db5e571fd01f063ae56aa2492f8d01a418815a (diff) | |
download | mariadb-git-c5c497164fbc48bcc50770ced833a07788082aaf.tar.gz |
post-review fixes. Now ROLLBACK is done in Format_description_log_event
mysql-test/t/mix_innodb_myisam_binlog.test:
fix for --ps-protocol
Diffstat (limited to 'sql/log_event.h')
-rw-r--r-- | sql/log_event.h | 30 |
1 files changed, 10 insertions, 20 deletions
diff --git a/sql/log_event.h b/sql/log_event.h index f108b890829..f422a91f358 100644 --- a/sql/log_event.h +++ b/sql/log_event.h @@ -312,14 +312,14 @@ struct sql_ex_info small chance that mysqld crashes in the middle of insert and end of the binlog would look like a Stop_log_event). - This flag is used to detect a restart after a crash, - and to provide "unbreakable" binlog. The problem is that on a crash - storage engines rollback automatically, while binlog does not. - To solve this we use this flag and automatically append ROLLBACK - to every non-closed binlog (append virtually, on reading, file itself - is not changed). If this flag is found, mysqlbinlog simply prints "ROLLBACK" - Replication master does not abort on binlog corruption, but takes it as EOF, - and replication slave forces a rollback in this case (see below). + This flag is used to detect a restart after a crash, and to provide + "unbreakable" binlog. The problem is that on a crash storage engines + rollback automatically, while binlog does not. To solve this we use this + flag and automatically append ROLLBACK to every non-closed binlog (append + virtually, on reading, file itself is not changed). If this flag is found, + mysqlbinlog simply prints "ROLLBACK" Replication master does not abort on + binlog corruption, but takes it as EOF, and replication slave forces a + rollback in this case. Note, that old binlogs does not have this flag set, so we get a a backward-compatible behaviour. @@ -328,16 +328,6 @@ struct sql_ex_info #define LOG_EVENT_BINLOG_IN_USE_F 0x1 /* - This flag is only used for fake Rotate_log_event. When a master, doing - binlog dump, reaches the end of the binlog and fakes a rotate to make - the slave to go to a new file, this flag is used if there was no - "natural" Rotate_log_event. - If this flag is set, slave will execute ROLLBACK before going further -*/ - -#define LOG_EVENT_FORCE_ROLLBACK_F 0x1 - -/* If the query depends on the thread (for example: TEMPORARY TABLE). Currently this is used by mysqlbinlog to know it must print SET @@PSEUDO_THREAD_ID=xx; before the query (it would not hurt to print it @@ -903,8 +893,8 @@ public: binary log) was created. In the other case (i.e. this event is at the start of a binary log created by FLUSH LOGS or automatic rotation), 'created' should be 0. This "trick" is used by MySQL - >=4.0.14 slaves to know if they must drop the stale temporary - tables or not. + >=4.0.14 slaves to know whether they must drop stale temporary + tables and whether they should abort unfinished transaction. Note that when 'created'!=0, it is always equal to the event's timestamp; indeed Start_log_event is written only in log.cc where |