-
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.
[#24818] YSQL: Add a test guc to fail drop commands
Summary: Add a test guc `yb_test_fail_all_drops` to fail all drop commands. The GUC can be set per-session by a superuser. Jira: DB-13922 Test Plan: Manually tested. ``` yugabyte=# CREATE TABLE test (t int); CREATE TABLE yugabyte=# CREATE VIEW test2 AS SELECT * FROM test; CREATE VIEW yugabyte=# CREATE INDEX test3 ON test(t); CREATE INDEX yugabyte=# SET yb_test_fail_all_drops=true; SET yugabyte=# DROP INDEX test3; ERROR: TEST: failed drop operation as requested HINT: GUC yb_test_fail_all_drops is set to true. yugabyte=# DROP VIEW test2; ERROR: TEST: failed drop operation as requested HINT: GUC yb_test_fail_all_drops is set to true. yugabyte=# DROP TABLE test; ERROR: TEST: failed drop operation as requested HINT: GUC yb_test_fail_all_drops is set to true. yugabyte=# RESET yb_test_fail_all_drops; RESET yugabyte=# DROP INDEX test3; DROP INDEX yugabyte=# DROP VIEW test2; DROP VIEW yugabyte=# DROP TABLE test; DROP TABLE ``` Reviewers: telgersma Reviewed By: telgersma Subscribers: yql Differential Revision: https://phorge.dev.yugabyte.com/D39772
- Loading branch information
1 parent
ee0a10e
commit 27d3917
Showing
4 changed files
with
22 additions
and
0 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
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