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,*: remove DistributionTypeSystemTenantOnly #116559

Conversation

stevendanna
Copy link
Collaborator

@stevendanna stevendanna commented Dec 15, 2023

sql,*: remove DistributionTypeSystemTenantOnly

Uses of DistributionTypeSystemTenantOnly represent places where UA/MT performance may not match single-tenant performance.

This replaces all uses of DistributionTypeSystemTenantOnly with DistributionTypeAlways.

Epic: none

Fixes #116534

sql: rename two DistributionType options

This commit does the following renaming to better represent the options:

  • DistributionTypeNone -> LocalDistribution
  • DistributionTypeAlways -> FullDistribution.

Release note: None

@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Member

@yuzefovich yuzefovich left a comment

Choose a reason for hiding this comment

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

Reviewed 11 of 11 files at r1, all commit messages.
Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @stevendanna)


pkg/sql/distsql_physical_planner.go line 153 at r1 (raw file):

const (
	// DistributionTypeNone does not distribute a plan across multiple instances.
	DistributionTypeNone = iota

Since we're now down to only two options, let's clean up this a bit. Should we just remove DistributionType altogether in favor of using distribute bool argument in its place? Or we could replace this type to use bool and rename two remaining options to something like LocalDistribution and FullDistribution. WDYT?

stevendanna and others added 2 commits March 13, 2024 09:56
Uses of DistributionTypeSystemTenantOnly represent places where UA/MT
performance may not match single-tenant performance.

This replaces all uses of DistributionTypeSystemTenantOnly with
DistributionTypeAlways.

Epic: none

Fixes cockroachdb#116534
This commit does the following renaming to better represent the options:
- `DistributionTypeNone` -> `LocalDistribution`
- `DistributionTypeAlways` -> `FullDistribution`.

Release note: None
@yuzefovich yuzefovich force-pushed the remove-distribution-type-system-tenant-only branch from 20470d4 to 5633695 Compare March 13, 2024 17:05
Copy link
Member

@yuzefovich yuzefovich left a comment

Choose a reason for hiding this comment

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

Reviewed 7 of 7 files at r2, 19 of 19 files at r3, all commit messages.
Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @stevendanna)


pkg/sql/distsql_physical_planner.go line 153 at r1 (raw file):

Previously, yuzefovich (Yahor Yuzefovich) wrote…

Since we're now down to only two options, let's clean up this a bit. Should we just remove DistributionType altogether in favor of using distribute bool argument in its place? Or we could replace this type to use bool and rename two remaining options to something like LocalDistribution and FullDistribution. WDYT?

I added another commit to do the renaming (while keeping the two-value enum).

@yuzefovich yuzefovich marked this pull request as ready for review March 13, 2024 17:07
@yuzefovich yuzefovich requested review from a team as code owners March 13, 2024 17:07
@yuzefovich yuzefovich requested review from dt, rharding6373 and DrewKimball and removed request for a team March 13, 2024 17:07
Copy link
Member

@yuzefovich yuzefovich left a comment

Choose a reason for hiding this comment

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

:lgtm: Perhaps someone else from @cockroachdb/sql-queries-prs should take a look too.

Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @DrewKimball, @dt, @rharding6373, and @stevendanna)

Copy link
Collaborator

@DrewKimball DrewKimball left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 4 of 11 files at r1, 7 of 7 files at r2, 19 of 19 files at r3, all commit messages.
Reviewable status: :shipit: complete! 2 of 0 LGTMs obtained (waiting on @dt, @rharding6373, and @stevendanna)

@yuzefovich
Copy link
Member

Thanks!

bors r+

@craig
Copy link
Contributor

craig bot commented Mar 13, 2024

@craig craig bot merged commit 928bd5c into cockroachdb:master Mar 13, 2024
17 of 30 checks passed
@stevendanna
Copy link
Collaborator Author

Thanks @yuzefovich !

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.

sql: reconsider remaining uses of DistributionTypeSystemTenantOnly
4 participants