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

pkg/server: add an extra server startup guardrail #110377

Merged
merged 1 commit into from
Sep 28, 2023

Conversation

healthy-pod
Copy link
Contributor

This code change prevents a SQL server from starting if its minimum supported binary version is greater than the tenant active version.

Release note: None
Epic: CRDB-26691

@blathers-crl
Copy link

blathers-crl bot commented Sep 11, 2023

It looks like your PR touches production code but doesn't add or edit any test code. Did you consider adding tests to your PR?

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

@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Contributor

@knz knz left a comment

Choose a reason for hiding this comment

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

thank you for this. Just a suggestion about phrasing.

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


pkg/server/server_sql.go line 1655 at r1 (raw file):

	// for the tenant cluster version.
	if tenantActiveVersion.Version.Less(s.execCfg.Settings.Version.BinaryMinSupportedVersion()) {
		return errors.WithHintf(errors.Newf("preventing SQL server from starting because its minimum supported "+

the error currently is phrased using our internal technical terms, but a user wouldn't necessarily know what to do with it.
Maybe flip the phrasing in the other direction:

"executable version is too new to run the current active logical version of the tenant"

(also maybe replace "tenant" by "virtual cluster")

then also update the hint to "finalize the version upgrade to at least X.Y or downgrade the executable version to at most Z.W".

This code change prevents a SQL server from starting if
its minimum supported binary version is greater than the
tenant active version.

Release note: None
Epic: CRDB-26691
@healthy-pod healthy-pod force-pushed the more-server-guardrails branch from 37b96b2 to 0b5306e Compare September 18, 2023 15:44
@healthy-pod healthy-pod requested a review from knz September 18, 2023 15:46
Copy link
Contributor

@knz knz 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 1 of 1 files at r2, all commit messages.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @stevendanna)

@healthy-pod
Copy link
Contributor Author

TFTR!

bors r=knz

@craig
Copy link
Contributor

craig bot commented Sep 28, 2023

Build failed (retrying...):

@craig
Copy link
Contributor

craig bot commented Sep 28, 2023

Build failed (retrying...):

@healthy-pod
Copy link
Contributor Author

bors retry

@craig
Copy link
Contributor

craig bot commented Sep 28, 2023

Already running a review

@craig
Copy link
Contributor

craig bot commented Sep 28, 2023

Build failed (retrying...):

@craig
Copy link
Contributor

craig bot commented Sep 28, 2023

Build failed (retrying...):

@craig
Copy link
Contributor

craig bot commented Sep 28, 2023

Build failed:

@healthy-pod
Copy link
Contributor Author

bors retry

@craig craig bot merged commit 39614e9 into cockroachdb:master Sep 28, 2023
@craig
Copy link
Contributor

craig bot commented Sep 28, 2023

Build succeeded:

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.

3 participants