-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[#25237] YSQL: PG15 upgrade: Block Create DB during major upgrade
Summary: Block the creation of new databases during for the entire ysql major upgrade process. Prior to this change the CreateNamespace call would only fail during the ysql major catalog upgrade phase, but the CREATE DATABASE SQL statement would fail trying to modify the system catalog tables. This happens because the ysql major catalog upgrade is just one of the steps in the upgrade, and we block the catalog for the entire upgrade. Since CREATE DATABASE is not yet an atomic DDL, this skips the cleanup of the partially created keyspace and cause further creation attempts of the same database to fail. - Unified the error message for all the DDLs that are blocked during the major upgrade. - Removed `VerifyDroppedColumnsForUpgrade` since it is never invoked. `CatalogManager::AlterTable` is completely skipped during the upgrade. - Removed some duplicate checks from `CatalogManager::DeleteYsqlDatabase` since its caller `CatalogManager::DoDeleteNamespace` performs the exact same checks already. Fixes #25237 Jira: DB-14425 Test Plan: YsqlMajorUpgradeDdlBlockingTest.CreateAndDropDBs Reviewers: telgersma, smishra Reviewed By: telgersma Subscribers: yql, ybase Differential Revision: https://phorge.dev.yugabyte.com/D41330
- Loading branch information
Showing
7 changed files
with
68 additions
and
148 deletions.
There are no files selected for viewing
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
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
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
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
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