-
Maria Couceiro authored
The worklog creates the infrastructure enabling two new timestamps that are associated with each transaction (instead of event or statement) in the binary log: - original_commit_timestamp: microseconds since the epoch when the transaction was committed on the original master. - immediate_commit_timestamp: microseconds since the epoch when the transaction was committed on the immediate master. Summary of relevant points covered by this worklog: 1) Two new fields, original_commit_timestamp and immediate_commit_timestamp, added to gtid_log_event. Commit time is recorded in write_gtid(), so the commit timestamp of a transaction is assumed to be the time of writing it to the binary log. 2) has_commit_timestamps flag added to the Gtid_event class, indicating whether the current gtid_log_event includes at least the immediate_commit_timestamp. If the gtid_log_event does not include any commit timestamp, it was replicated from a server with a MySQL version lower than 8.0 and has to be processed accordingly. 4) The new body of gtid_log_event consists of: - only original_commit_timestamp at the original server, since original and immediate commit timestamps are same at this server; - both original and immediate commit timestamps in any other 8.0+ server.
Maria Couceiro authoredThe worklog creates the infrastructure enabling two new timestamps that are associated with each transaction (instead of event or statement) in the binary log: - original_commit_timestamp: microseconds since the epoch when the transaction was committed on the original master. - immediate_commit_timestamp: microseconds since the epoch when the transaction was committed on the immediate master. Summary of relevant points covered by this worklog: 1) Two new fields, original_commit_timestamp and immediate_commit_timestamp, added to gtid_log_event. Commit time is recorded in write_gtid(), so the commit timestamp of a transaction is assumed to be the time of writing it to the binary log. 2) has_commit_timestamps flag added to the Gtid_event class, indicating whether the current gtid_log_event includes at least the immediate_commit_timestamp. If the gtid_log_event does not include any commit timestamp, it was replicated from a server with a MySQL version lower than 8.0 and has to be processed accordingly. 4) The new body of gtid_log_event consists of: - only original_commit_timestamp at the original server, since original and immediate commit timestamps are same at this server; - both original and immediate commit timestamps in any other 8.0+ server.
Loading