-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
batch-system: use different default max batch size between master and release branch #9917
batch-system: use different default max batch size between master and release branch #9917
Conversation
@@ -13,8 +13,15 @@ pub struct Config { | |||
|
|||
impl Default for Config { | |||
fn default() -> Config { | |||
// FIXME: if hibernate regions is enabled by default on release branch, we can use | |||
// the same configuration here. | |||
let max_batch_size = if tikv_util::build_on_master_branch() { |
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 changing it at validate
method according to the value of hibernate-region
?
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.
What if users set the max-batch-size
? Use a Option
?
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.
Yes.
Signed-off-by: gengliqi <gengliqiii@gmail.com>
6c4f3f0
to
4ba4cba
Compare
Signed-off-by: gengliqi <gengliqiii@gmail.com>
55301b0
to
3b59390
Compare
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
Signed-off-by: gengliqi <gengliqiii@gmail.com>
[REVIEW NOTIFICATION] This pull request has been approved by:
To complete the pull request process, please ask the reviewers in the list to review by filling The full list of commands accepted by this bot can be found here. Reviewer can indicate their review by writing |
/merge |
@gengliqi: It seems you want to merge this PR, I will help you trigger all the tests: /run-all-tests You only need to trigger If you have any questions about the PR merge process, please refer to pr process. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository. |
This pull request has been accepted and is ready to merge. Commit hash: 56dd95f
|
/run-all-tests |
/run-all-tests |
/merge |
@zhouqiang-cl: It seems you want to merge this PR, I will help you trigger all the tests: /run-all-tests You only need to trigger If you have any questions about the PR merge process, please refer to pr process. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository. |
Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
cherry pick to release-5.0 in PR #9930 |
Signed-off-by: gengliqi gengliqiii@gmail.com
What problem does this PR solve?
Problem Summary:
On master, the hibernate region is enabled by default so the max-batch-size can be larger.
However it is disabled by default on the release branch, the max-batch-size is too small which may cause many problems, e.g. too small write batch, hunger problem.
You can also see #9020 for more details.
What is changed and how it works?
What's Changed:
use different default max batch size between master and release branch.
Related changes
pingcap/docs
/pingcap/docs-cn
:Tests
Side effects
Release note
hibernate-regions
is enabled, the default value ofstore-max-batch-size
is 256, otherwise it's 1024.apply-max-batch-size
from 1024 to 256.