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: add a test that verifies that the system database schema version is correct after upgrade #121914

Closed
RaduBerinde opened this issue Apr 7, 2024 · 0 comments · Fixed by #123084
Assignees
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. P-2 Issues/test failures with a fix SLA of 3 months T-sql-foundations SQL Foundations Team (formerly SQL Schema + SQL Sessions)

Comments

@RaduBerinde
Copy link
Member

RaduBerinde commented Apr 7, 2024

In the 23.2 release cycle, #104714 added a system table but the upgrade does not bump the system database schema version. The PR does change the bootstrap version, so depending on whether we created a cluster on 23.2 or upgraded a cluster from 23.1, we end up with a different schema version.

To prevent this in the future, we should have a test that upgrades a cluster from the previous version and then asserts that the system database schema version is the same as the bootstrap version.

Somewhat related - it's a bit unfortunate that the schema version is an upgrade version (e.g 23.1-32) which will later require special code to determine if this version is acceptable given a minimum supported cluster version of 23.2. It would be ideal if the final schema version matches the latest cluster version. Perhaps the final upgrade step could always be a "finalize schema version" where we bump the version to the bootstrap version.

Jira issue: CRDB-37616

Epic CRDB-37763

@RaduBerinde RaduBerinde added the C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. label Apr 7, 2024
@blathers-crl blathers-crl bot added the T-sql-foundations SQL Foundations Team (formerly SQL Schema + SQL Sessions) label Apr 7, 2024
@fqazi fqazi added the P-2 Issues/test failures with a fix SLA of 3 months label Apr 9, 2024
@exalate-issue-sync exalate-issue-sync bot removed the P-2 Issues/test failures with a fix SLA of 3 months label Apr 9, 2024
@exalate-issue-sync exalate-issue-sync bot added the P-2 Issues/test failures with a fix SLA of 3 months label Apr 25, 2024
@rafiss rafiss self-assigned this Apr 25, 2024
@craig craig bot closed this as completed in 6ff7eca May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. P-2 Issues/test failures with a fix SLA of 3 months T-sql-foundations SQL Foundations Team (formerly SQL Schema + SQL Sessions)
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants