Skip to content

replication: support parsing event with header only and no checksum #431

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 9, 2019

Conversation

amyangfei
Copy link
Contributor

@amyangfei amyangfei commented Oct 8, 2019

What problem does this PR solve?

When parsing a binlog event that has event header only and no checksum data, go-mysql will return error invalid event header, event size is 19, too small

Ref to MySQL doc, STOP_EVENT has event header only, so if binlog checksum is not enabled, there may exist binlog event with event size 19.

Besides the binlog event checksum was disabled by default before MariaDB 10.2.1, so this problem occurs often in MariaDB 10.1.x

What is changed and how it works?

Allow binlog event size equals to 19

@amyangfei
Copy link
Contributor Author

PTAL @siddontang @GregoryIan @csuzhangxc

@siddontang siddontang merged commit f66c8b3 into go-mysql-org:master Oct 9, 2019
@amyangfei amyangfei deleted the fix-header-only-ev branch October 9, 2019 01:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants