[MDEV-5873] MASTER_GTID_WAIT() works incorrectly in case of out-of-order GTIDs in master binlog Created: 2014-03-16  Updated: 2022-09-12  Resolved: 2022-09-12

Status: Closed
Project: MariaDB Server
Component/s: OTHER
Affects Version/s: 10.0.9
Fix Version/s: N/A

Type: Bug Priority: Minor
Reporter: Kristian Nielsen Assignee: Kristian Nielsen
Resolution: Won't Fix Votes: 0
Labels: None


 Description   

If manual transactions are made on the slave, or in case of multi-master ring
configured without separate domain ids, two GTIDs with the same sequence
number and domain id (but distinct server_id) may occur.

MASTER_GTID_WAIT() does not correctly deal with this situation, as it compares
only against the sequence number within each domain. This means that it may
return too early, ie. waiting for the second of two such GTIDs with same
sequence number will return already when the first of them has been applied on
the slave.

This needs to be fixed. The master already sends GTID_LIST events that
contain the current binlog state, giving the highest sequence number applied
for each (domain_id, server_id) tuple. The slave should use and maintain this
binlog state when handling MASTER_GTID_WAIT(), so that the wait is for
sequence number within the full (domain_id, server_id) tuple, not just the
domain.



 Comments   
Comment by Sergei Golubchik [ 2022-09-12 ]

10.0 was EOLed in March 2019

Generated at Thu Feb 08 07:07:41 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.