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

sql/catalog: add region_liveness table #107903

Merged
merged 2 commits into from Aug 22, 2023

Conversation

fqazi
Copy link
Collaborator

@fqazi fqazi commented Jul 31, 2023

This adds a new region_liveness table and a migration to create this table for existing clusters, allowing us to introduce the concept of region liveness in later PRs. This will allow certain system tables to be configured as SURVIVE REGION later on.

Epic: CRDB-28158

@cockroach-teamcity
Copy link
Member

This change is Reviewable

@fqazi fqazi force-pushed the regionLivenessTable branch 2 times, most recently from b3f6fe4 to 51b470f Compare August 1, 2023 16:11
@blathers-crl
Copy link

blathers-crl bot commented Aug 1, 2023

Thank you for updating your pull request.

Before a member of our team reviews your PR, I have some potential action items for you:

  • We notice you have more than one commit in your PR. We try break logical changes into separate commits, but commits such as "fix typo" or "address review commits" should be squashed into one commit and pushed with --force
  • When CI has completed, please ensure no errors have appeared.

I was unable to automatically find a reviewer. You can try CCing one of the following members:

  • A person you worked with closely on this PR.
  • The person who created the ticket, or a CRDB organization member involved with the ticket (author, commenter, etc.).
  • Join our community slack channel and ask on #contributors.
  • Try find someone else from here.

🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.

@blathers-crl blathers-crl bot added O-community Originated from the community X-blathers-untriaged blathers was unable to find an owner labels Aug 1, 2023
@fqazi fqazi force-pushed the regionLivenessTable branch 2 times, most recently from dcf4ca3 to 4c92325 Compare August 1, 2023 20:29
@fqazi fqazi removed O-community Originated from the community X-blathers-untriaged blathers was unable to find an owner labels Aug 1, 2023
@fqazi fqazi force-pushed the regionLivenessTable branch 4 times, most recently from 34b8589 to 85f347d Compare August 3, 2023 03:21
@fqazi fqazi marked this pull request as ready for review August 3, 2023 03:21
@fqazi fqazi requested review from a team as code owners August 3, 2023 03:21
@fqazi fqazi requested review from rhu713 and michae2 and removed request for a team August 3, 2023 03:21
@fqazi fqazi force-pushed the regionLivenessTable branch 4 times, most recently from db8ebf5 to ee8733d Compare August 9, 2023 14:54
@fqazi fqazi requested a review from JeffSwenson August 13, 2023 20:55
Copy link
Collaborator

@JeffSwenson JeffSwenson left a comment

Choose a reason for hiding this comment

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

This is great 💯

pkg/sql/region_util.go Show resolved Hide resolved
@fqazi fqazi requested a review from a team as a code owner August 17, 2023 04:01
Previously, we had no way of tracking region liveness
which could can be used to improve behaviour on region
failures. To address this, this patch introduces the
system.region_liveness table.

Epic: CRDB-28158

Informs: cockroachdb#103727

Release note: None
@fqazi fqazi force-pushed the regionLivenessTable branch 2 times, most recently from e331c68 to 7d5efa7 Compare August 17, 2023 04:22
@fqazi fqazi requested a review from JeffSwenson August 17, 2023 15:09
Previously, the region liveness table was only
created for new clusters. This was inadequate because
we need this table to be created for existing ones too.
To address this, this patch adds a migration to create
this table and clear its key space, since its been
reused.

Epic: CRDB-28158
Release note: None
Copy link
Collaborator

@JeffSwenson JeffSwenson left a comment

Choose a reason for hiding this comment

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

LGTM

@fqazi
Copy link
Collaborator Author

fqazi commented Aug 22, 2023

bors r+

@craig
Copy link
Contributor

craig bot commented Aug 22, 2023

Build succeeded:

@craig craig bot merged commit e5a9669 into cockroachdb:master Aug 22, 2023
7 checks passed
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.

None yet

3 participants