-
Notifications
You must be signed in to change notification settings - Fork 3.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
release-21.1: backport zone config validation changes #63834
Merged
ajstorm
merged 6 commits into
cockroachdb:release-21.1
from
otan-cockroach:backport21.1-63461-63273-63502-63512
Apr 19, 2021
Merged
release-21.1: backport zone config validation changes #63834
ajstorm
merged 6 commits into
cockroachdb:release-21.1
from
otan-cockroach:backport21.1-63461-63273-63502-63512
Apr 19, 2021
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In the past there were cases where a table locality change (even one where override was specified) would not clear all of the multi-region zone configuration fields for all zone configurations. The simplest example is if you had a zone configuration manually specified by the user on an index and you were ALTERing the table locality to REGIONAL BY TABLE or GLOBAL. Since neither of these transitions look at the index zone configuration, it would remain untouched, and future locality changes would still require the override. This commit change the behavior such that if override is specified, all multi-region fields of the zone configuration will be cleared and a future table locality change will not require override. Release note: None
Previously we were returning an inaccurate error message when a user modified zone config was present on a multi-region table. This was due to the fact that we'd key off of num_replicas being set in a placeholder zone config and think that that was the difference between the two zone configs. In actuality, the difference was in the subzones. This commit allows for the reporting of the true difference, the presence of the index in the subzones. Release note: None
Involves peeping into the mutations and excluding the new indexes being created -- these will not have the correct zone configs set on them. Release note (bug fix): Fix a bug where crdb_internal.validate_multi_region_zone_configs() fails during a REGIONAL BY ROW locality transition.
Transitioning regions can result in transient state which is hard to reason about and validate during a concurrent operation with REGIONAL BY ROW changes. To alleviate this, we relax the validation by removing the transitioning regions from the validation path. Steps: * Change RegionConfig to optionally include transitioning regions. * Make SynthesizeRegionConfig include transitioning regions. * Change the validation interface to surface transitioning regions. Remove this from regional by row zone config validation. Release note: None
Release note: None
Use the option method instead to decide to read from the cache. Release note: None
otan
requested review from
arulajmani,
ajstorm,
a team and
adityamaru
and removed request for
a team
April 19, 2021 08:54
ajstorm
reviewed
Apr 19, 2021
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.
Reviewable status: complete! 1 of 0 LGTMs obtained (waiting on @adityamaru and @arulajmani)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Backport:
Please see individual PRs for details.
/cc @cockroachdb/release
This is needed for @arulajmani's GA blocker -- #63462. They must be backported together as otherwise there is some very ugly merge conflicts to resolve.