-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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
planner, sessionctx: enable indexMerge by default #29617
Conversation
enable tidb_enable_index_merge by default
[REVIEW NOTIFICATION] This pull request has not been approved. 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 submitting an approval review. |
Please follow PR Title Format:
Or if the count of mainly changed packages are more than 3, use
After you have format title, you can leave a comment |
/run-check_title |
@@ -1075,7 +1075,7 @@ var defaultSysVars = []*SysVar{ | |||
s.SetEnableCascadesPlanner(TiDBOptOn(val)) | |||
return nil | |||
}}, | |||
{Scope: ScopeGlobal | ScopeSession, Name: TiDBEnableIndexMerge, Value: Off, Type: TypeBool, SetSession: func(s *SessionVars, val string) error { | |||
{Scope: ScopeGlobal | ScopeSession, Name: TiDBEnableIndexMerge, Value: On, Type: TypeBool, SetSession: func(s *SessionVars, val string) error { |
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.
This will only change the default for new installations. I believe this is fine, but I will wait for you to confirm (and update the release note).
If you'd like to change for existing installs, a bootstrap task is needed (session/bootstrap.go).
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.
(1) Please make sure this works for 4.0 to 5.0 upgrade too, since from analyze-2.0 feature we found it only works for intra-5.0 upgrade but does not work for the 4.0 to 5.0 upgrade which changes the default anyway no matter it is existing or new installs;
(2) Also @guo-shaoge is working on GA index merge in Sprint 6. I'd suggest to make this change together with index merge GA feature.
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.
I think just change the default for new installations is enough. Change for existing installs will results in plan changes, which will give the user "surprise". That's not what I expected.
And I will talk to @guo-shaoge later.
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.
The problem here is that approach we identify whether it's an existing or new install only works for 5.x but not 4.x, which means all the existing system from 4.x will be impacted and default will be changed after upgrading to 5.x.
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.
- config, session: promise the compatibility of oom-action when upgrading #22102 changed the default
oom-action
, which works for all situations(3.0 to 4.0 and 4.0 to 5.0).
Butoom-action
is a config item, I am not sure it works for sysvars. - IMO, it's better to enable index merge after it's official GA. We are working on it.
/run-common-test |
@Yui-Song: PR needs rebase. 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 kubernetes/test-infra repository. |
enable tidb_enable_index_merge by default
What problem does this PR solve?
Issue Number: close #29597
Problem Summary:
What is changed and how it works?
Enable tidb_enable_index_merge by default
Check List
Tests
Side effects
Documentation
Release note