Repository navigation
feat: add sys.query_context_parameters system table - #223
Closed
FrankChen021 wants to merge 9 commits into
Closed
FrankChen021 wants to merge 9 commits into
FrankChen021 wants to merge 9 commits into
Conversation
FrankChen021
force-pushed
the
codex/migrate-sql-query-context
branch
2 times, most recently
from
October 12, 2026 03:06
645f387 to
cb1d66d
Compare
FrankChen021
force-pushed
the
codex/migrate-sql-query-context
branch
from
October 12, 2026 03:12
cb1d66d to
afbc84f
Compare
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 12, 2026 06:57
64571df to
73db462
Compare
FrankChen021
force-pushed
the
codex/migrate-sql-query-context
branch
2 times, most recently
from
October 12, 2026 08:34
d6c60cb to
f4c0c6a
Compare
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 12, 2026 10:25
64489b5 to
ca848b9
Compare
FrankChen021
force-pushed
the
codex/migrate-sql-query-context
branch
from
October 13, 2026 06:05
f4c0c6a to
752ea44
Compare
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 13, 2026 06:08
a124bc1 to
039f60a
Compare
FrankChen021
force-pushed
the
codex/migrate-sql-query-context
branch
from
October 13, 2026 06:11
752ea44 to
de3fcb1
Compare
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 13, 2026 06:11
039f60a to
f33b7dd
Compare
FrankChen021
force-pushed
the
codex/migrate-sql-query-context
branch
from
October 13, 2026 06:12
de3fcb1 to
9a0056a
Compare
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 13, 2026 06:13
f33b7dd to
85f70c5
Compare
FrankChen021
force-pushed
the
codex/migrate-sql-query-context
branch
from
October 13, 2026 07:00
9a0056a to
1ba7ad6
Compare
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 13, 2026 07:04
85f70c5 to
e631e4e
Compare
FrankChen021
changed the base branch from
codex/migrate-sql-query-context
to
codex/migrate-query-context-reference
October 13, 2026 07:04
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 13, 2026 08:25
7590609 to
5f15f94
Compare
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 13, 2026 09:33
67833f6 to
40c54ec
Compare
…ache#20541) Addresses four problems: 1) Provide PhysicalSegmentColumnInspector from PartialQueryableIndexSegment. Previously it was not provided, so segmentMetadata queries were not able to report types. 2) Look at all cluster groups when determining capabilities, not just the first one. (They can differ in the details, like auto-determined type and hasMultipleValues.) 3) Use the DimensionIndexer's ColumnFormat when writing columns in cluster groups and projections. Previously the ColumnFormat present at creation time was used, which could differ in details (such as hasMultipleValues). This caused multi-valued columns to be incorrectly persisted, in situations where the persist logic did not realize they were multi-value. 4) Updates Capable.or and Capable.and to use correct 3-valued logic. This made certain new code simpler to write, and as far as I can tell, will only have positive effects on existing callers.
CodeQL Action v3 runs on Node.js 20 and is deprecated in December 2026. v4 runs on Node.js 24.
* Enable Dependabot version updates for GitHub Actions * Exempt codeql-action from the GitHub Actions cooldown * Trim cooldown comments * Use a 7-day cooldown for GitHub Actions instead of exempting codeql-action
…he#20450) * perf: cache incremental-index expression plans * fix: avoid sharing mutable expression state * fix: return fresh expressions from plan cache * test: use daemon executor for expression cache concurrency * docs: explain expression plan cache array * perf: reuse expression selectors during ingestion * test: cover expression selector reuse with arrays * test: clarify expression ingestion expectation * perf: add expression ingestion benchmark * fix: reevaluate non-deterministic ingestion expressions
* refactor: migrate query context reference parameters * fix: address review findings on query context descriptors - Merge the user context over default contexts with QueryContexts.withDefaults, so a null user value falls back to the configured default on both the SQL and native paths. - Declare maxSubqueryBytes as a string parameter that accepts the forms the subquery guardrail accepts. - Deprecate the key constants replaced by descriptors for removal, and migrate their remaining uses. - Escape default descriptions and ignore CRLF line endings in the generated documentation check. * fix: address second review of query context descriptors
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 14, 2026 06:36
cf0cc4c to
d0ad0c7
Compare
Lists the query context parameters users can set, with their types, defaults, applicability and the default the Broker applies. Also renames Visibility.INTERNAL to SYSTEM.
FrankChen021
force-pushed
the
codex/sys-query-context-parameters
branch
from
October 14, 2026 07:04
d0ad0c7 to
a292a85
Compare
Owner
Author
|
Split: system table moved upstream to apache#20586; web console change in #226. |
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.
Description
Stacked on apache#20556. Adds
sys.query_context_parameters, which lists the query context parameters users can set, built from theQueryContextParameterscatalog.INTERNALparameters are excluded. Descriptions are normalized to one line when the descriptor is built; an enum's description lists its accepted values.name,type,range,default_value,effective_value,effective_source,default_description,description,visibility,since,deprecation_messagequery_languages(SQL,JSON),engines,native_query_types,statement_typesis_nullable,is_deprecateddefault_valueis the built-in default.effective_valueis the default this Broker applies when a query doesn't set the parameter: the Broker dynamic configuration'squeryContext, else thedruid.query.default.context.<name>runtime property, else the built-in default;effective_sourcesays which. Anullin the dynamic configuration unsets the key, so the built-in default applies.QueryConfigProvidergainsgetDynamicContext()so the table can tell the dynamic overrides apart.Unlike
sys.servers, the table doesn't requireSTATEREAD: any user who can querysystables can read the catalog. Only the effective defaults come from Broker configuration, so withoutREADon theCONFIGresource the query still succeeds, buteffective_valueis null andeffective_sourceisUNAUTHORIZEDin every row.native_query_typesandstatement_typesare empty when a parameter applies to all native query types or statement types, and null when it doesn't apply to native queries or SQL at all.The web console's SQL editor now loads the public parameters from this table and suggests them after
SET, with each parameter's type, description, default and deprecation in the completion popup. WithoutCONFIGread access it shows the built-in default and notes that the Broker may override it. If the table can't be read (an older Druid), it falls back to the previous fixed list.CloneQueryModenow serializes by its JSON name (excludeClones), the same fix as apache#20557, so itsdefault_valuematches what queries accept.The table runs on the Bindable path, where array columns can be selected and indexed but not used with Druid array functions such as
ARRAY_CONTAINS. Those need the native system-table path (apache#20183).This PR has: