docs: add Query Guard plugin docs for banning DROP TABLE/DATABASE - #2654
Merged
Conversation
Document the enterprise query_guard plugin configuration added in GreptimeTeam/greptimedb-enterprise#832, including ban_drop_table and ban_drop_database options, SQL/gRPC enforcement behavior, and deployment caveats. Also document the pre-existing disallow_cross_catalog_query behavior and cross-link from the DROP SQL reference.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds end-user documentation for the GreptimeDB Enterprise Query Guard plugin, explaining how it can enforce hard bans on destructive DROP TABLE / DROP DATABASE operations (and documenting the existing cross-catalog restriction behavior) across supported protocols.
Changes:
- Added a new Query Guard documentation page in both English and Chinese, including behavior overview, protocol coverage, configuration, and caveats.
- Registered the new page in the Enterprise → Deployments & Administration sidebar.
- Added cross-links from the
DROPSQL reference pages (EN + ZH) to the new Query Guard documentation.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| sidebars.ts | Adds the Query Guard doc to the Enterprise → Deployments & Administration sidebar. |
| i18n/zh/docusaurus-plugin-content-docs/current/reference/sql/drop.md | Adds a tip linking to Query Guard as a way to ban DROP statements for all users. |
| i18n/zh/docusaurus-plugin-content-docs/current/enterprise/deployments-administration/query-guard.md | New Chinese Query Guard page covering behavior, configuration, and caveats. |
| docs/reference/sql/drop.md | Adds a tip linking to Query Guard as a way to ban DROP statements for all users. |
| docs/enterprise/deployments-administration/query-guard.md | New English Query Guard page covering behavior, configuration, and caveats. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Deploying greptime-docs with
|
| Latest commit: |
7bef878
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://0a33b32d.greptime-docs.pages.dev |
| Branch Preview URL: | https://docs-query-guard.greptime-docs.pages.dev |
shuiyisong
reviewed
Jul 28, 2026
shuiyisong
left a comment
Contributor
There was a problem hiding this comment.
Two source-validated documentation findings.
…g DDL/Flight) Address review feedback: the query_guard plugin unconditionally rejects COPY statements, cross-catalog gRPC DDL requests, and Flight bulk inserts targeting a different catalog whenever it is enabled, independent of the DROP bans.
Address review feedback: only the structured gRPC DDL request lacks a drop-database variant; SQL statements sent over gRPC still pass through the SQL query interceptors, so both DROP bans apply there.
shuiyisong
approved these changes
Jul 28, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What's changed
Add documentation for the GreptimeDB Enterprise Query Guard plugin, including the new
ban_drop_table/ban_drop_databaseoptions introduced in GreptimeTeam/greptimedb-enterprise#832.enterprise/deployments-administration/query-guard(EN + ZH):DROP TABLE/DROP DATABASE; gRPC path rejectsDROP TABLEDDL requests (no drop-database variant in gRPC)[[plugins]] [plugins.query_guard]withenable,ban_drop_table,ban_drop_databasedisallow_cross_catalog_querybehavior (documented here for the first time)DROPSQL reference (EN + ZH) pointing to the new pageVerification
pnpm typecheck✅pnpm build(EN) ✅DOC_LANG=zh pnpm build(ZH) ✅