Skip to content
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

sort mariadb gtid set #545

Merged
merged 6 commits into from
Apr 9, 2021
Merged

Conversation

zeminzhou
Copy link
Contributor

当 mariadb gtid中包含多个 server id时,由于 Sets是一个map结构,输出 set的顺序随机,导致最终输出的 gtid字符串内容不同。本 PR,在输出前对内容进行排序后输出,保证输出结果的一致。

@lance6716
Copy link
Collaborator

Hi @zeminzhou, please add a unit test about this behaviour

@zeminzhou
Copy link
Contributor Author

Hi @zeminzhou, please add a unit test about this behaviour

I'm sorry I just saw this email notification. Glad to read your comments, I will add a unit test for this pr tomorrow.

mysql/mariadb_gtid.go Outdated Show resolved Hide resolved
mysql/mariadb_gtid_test.go Outdated Show resolved Hide resolved
@lance6716 lance6716 merged commit e4bb47e into go-mysql-org:master Apr 9, 2021
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