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

binlog: update config for backward compatibility #9688

Merged
merged 12 commits into from
Mar 14, 2019

Conversation

WangXiangUSTC
Copy link
Contributor

@WangXiangUSTC WangXiangUSTC commented Mar 13, 2019

What problem does this PR solve?

pr #9625 break the backward compatibility,
this pr fix it

What is changed and how it works?

  1. change binlog.enable's type to bool as before
  2. add a new config binlog.automode, if automode is true, enable binlog by global system variable 'tidb_log_bin'

Check List

Tests

  • Unit test
  • Manual test (set binlog.enable and binlog.mode)

Related changes

  • Need to update the documentation
  • Need to be included in the release note

Copy link
Member

@jackysp jackysp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jackysp
Copy link
Member

jackysp commented Mar 13, 2019

Please fix CI.

@gregwebs
Copy link
Contributor

This looks like a great solution. I have one concern: the new variable is a string with one allowed value besides empty: "auto". Can we validate this so that we reject other values?

We could instead make the "mode" a boolean so that it will be validated, but these changes show that a string is more extensible for future changes.

@WangXiangUSTC
Copy link
Contributor Author

@gregwebs I changed Mode to AutoMode, and change type to bool

@codecov
Copy link

codecov bot commented Mar 13, 2019

Codecov Report

Merging #9688 into master will increase coverage by 0.0133%.
The diff coverage is 0%.

@@               Coverage Diff                @@
##             master      #9688        +/-   ##
================================================
+ Coverage   67.3493%   67.3627%   +0.0134%     
================================================
  Files           378        378                
  Lines         79542      79544         +2     
================================================
+ Hits          53571      53583        +12     
+ Misses        21193      21185         -8     
+ Partials       4778       4776         -2

@WangXiangUSTC
Copy link
Contributor Author

/run-all-tests

@WangXiangUSTC WangXiangUSTC added the status/LGT1 Indicates that a PR has LGTM 1. label Mar 13, 2019
@gregwebs
Copy link
Contributor

LGTM

@WangXiangUSTC
Copy link
Contributor Author

/run-all-tests

2 similar comments
@WangXiangUSTC
Copy link
Contributor Author

/run-all-tests

@WangXiangUSTC
Copy link
Contributor Author

/run-all-tests

@WangXiangUSTC
Copy link
Contributor Author

/run-common-test

1 similar comment
@WangXiangUSTC
Copy link
Contributor Author

/run-common-test

Copy link
Member

@zz-jason zz-jason left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@zz-jason zz-jason added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Mar 14, 2019
@zz-jason
Copy link
Member

/run-all-tests

@XuHuaiyu
Copy link
Contributor

/run-common-test tidb-test=pr/739
/run-integration-common-test tidb-test=pr/739

@WangXiangUSTC WangXiangUSTC merged commit 792429d into pingcap:master Mar 14, 2019
@WangXiangUSTC WangXiangUSTC deleted the xiang/binlog_compatibility branch March 14, 2019 08:53
WangXiangUSTC added a commit to WangXiangUSTC/tidb that referenced this pull request Mar 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants