-
Notifications
You must be signed in to change notification settings - Fork 188
relay: fix GTID recover after relay log recovered #335
Conversation
/run-all-tests |
1 similar comment
/run-all-tests |
Codecov Report
@@ Coverage Diff @@
## master #335 +/- ##
=========================================
Coverage 60.147% 60.147%
=========================================
Files 135 135
Lines 15236 15236
=========================================
Hits 9164 9164
Misses 5173 5173
Partials 899 899 |
@amyangfei @WangXiangUSTC PTAL |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rest LGTM
}, | ||
{ | ||
before: "00c04543-f584-11e9-a765-0242ac120002:40-60:70:80-100", | ||
end: "00c04543-f584-11e9-a765-0242ac120002:45-55:70:85-95", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about also add a case before's interval's num is different with end, for example:
before: "00c04543-f584-11e9-a765-0242ac120002:40-60:70:80-100",
end: "00c04543-f584-11e9-a765-0242ac120002:45-55:85-95"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 added in feeed29.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about also add for mariadb
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/run-all-tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
cherry pick to release-1.0 in PR #339 |
The problem in PR description is caused by MySQL slave forget to set
since now we introduced #1430 , the |
What problem does this PR solve?
MySQL may not save all previous GTID sets in its binlog file as
Previous_gtids
event in some special scenarios (not confirmed yet, but maybe a bug, ref https://bugs.mysql.com/bug.php?id=93809).example:
00c04543-f584-11e9-a765-0242ac120002:1-60
Previous_gtids
event:00c04543-f584-11e9-a765-0242ac120002:45-60
00c04543-f584-11e9-a765-0242ac120002:45-60
, but this should still be00c04543-f584-11e9-a765-0242ac120002:1-60
.00c04543-f584-11e9-a765-0242ac120002:45-60
to request the master is wrong, because this will cause the master to send binlog events in00c04543-f584-11e9-a765-0242ac120002:1-44
. if this events are purged, an error (ERROR 1236 (HY000): The slave is connecting using CHANGE MASTER TO MASTER_AUTO_POSITION = 1, but the master has purged binary logs containing GTIDs that the slave requires.
) will reported; if this events are not purged, they will be sent again.What is changed and how it works?
only truncate the
Stop
of the GTID set intervals, like truncating00c04543-f584-11e9-a765-0242ac120002:1-60
with00c04543-f584-11e9-a765-0242ac120002:40-50
will get00c04543-f584-11e9-a765-0242ac120002:1-50
.Check List
Tests
Related changes