diff options
author | unknown <knielsen@knielsen-hq.org> | 2014-03-12 00:14:49 +0100 |
---|---|---|
committer | unknown <knielsen@knielsen-hq.org> | 2014-03-12 00:14:49 +0100 |
commit | 8b9b7ec395df111f886224a565b63a1a312e5679 (patch) | |
tree | a44e2719f727964a854ed9c45e26e7314f6b62a4 /sql/rpl_gtid.h | |
parent | 2c2478b82260f5110ea2c5bed3c6c7bcd3558453 (diff) | |
download | mariadb-git-8b9b7ec395df111f886224a565b63a1a312e5679.tar.gz |
MDEV-5804: If same GTID is received on multiple master connections in multi-source replication, the event is double-executed causing corruption or replication failure
Some fixes, mainly to make it work in non-parallel replication mode also
(--slave-parallel-threads=0).
Patch should be fairly complete now.
Diffstat (limited to 'sql/rpl_gtid.h')
-rw-r--r-- | sql/rpl_gtid.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sql/rpl_gtid.h b/sql/rpl_gtid.h index aef1ca9e403..3e9e2fce25f 100644 --- a/sql/rpl_gtid.h +++ b/sql/rpl_gtid.h @@ -92,6 +92,7 @@ struct gtid_waiting { class Relay_log_info; +struct rpl_group_info; /* Replication slave state. @@ -171,7 +172,7 @@ struct rpl_slave_state void truncate_hash(); ulong count() const { return hash.records; } int update(uint32 domain_id, uint32 server_id, uint64 sub_id, - uint64 seq_no, const Relay_log_info *rli); + uint64 seq_no, rpl_group_info *rgi); int truncate_state_table(THD *thd); int record_gtid(THD *thd, const rpl_gtid *gtid, uint64 sub_id, bool in_transaction, bool in_statement); @@ -187,10 +188,10 @@ struct rpl_slave_state element *get_element(uint32 domain_id); int put_back_list(uint32 domain_id, list_element *list); - void update_state_hash(uint64 sub_id, rpl_gtid *gtid, - const Relay_log_info *rli); + void update_state_hash(uint64 sub_id, rpl_gtid *gtid, rpl_group_info *rgi); int record_and_update_gtid(THD *thd, struct rpl_group_info *rgi); - int check_duplicate_gtid(rpl_gtid *gtid, const Relay_log_info *rli); + int check_duplicate_gtid(rpl_gtid *gtid, rpl_group_info *rgi); + void release_domain_owner(rpl_group_info *rgi); }; |