[BugFix] Fix SHOW/DESCRIBE statement routing under cluster.pluggable.dataformat setting#5528
Conversation
PR Reviewer Guide 🔍(Review updated until commit 3a8812a)Here are some key observations to aid the review process:
|
PR Code Suggestions ✨Latest suggestions up to 3a8812a Explore these optional code suggestions:
Previous suggestionsSuggestions up to commit 9468152
Suggestions up to commit 5d53ddc
|
5d53ddc to
80233de
Compare
|
Persistent review updated to latest commit 80233de |
80233de to
9468152
Compare
|
Persistent review updated to latest commit 9468152 |
…uster composite When cluster.pluggable.dataformat=composite, isAnalyticsIndex routed every query to the analytics engine, which cannot serve the system catalog (*_ODFE_SYS_TABLE, .DATASOURCES) that SHOW/DESCRIBE resolve. Detect system-catalog queries (including legacy-syntax SHOW/DESCRIBE that the V2 parser rejects) and keep them on the default pipeline while data queries continue to the analytics engine. Also log query routing to the analytics engine at both call sites. Signed-off-by: Chen Dai <daichen@amazon.com>
9468152 to
3a8812a
Compare
|
Persistent review updated to latest commit 3a8812a |
Description
PR #5486 introduced the
cluster.pluggable.dataformatsetting. When enabled, all queries are routed to the Analytics Engine, which does not supportSHOWorDESCRIBEstatement, causing both to fail. This PR fixes the routing by:cluster.pluggable.dataformat=composite,SHOW TABLES,DESCRIBE, andSHOW DATASOURCESqueries are now routed back to default query pipeline instead of analytics engine.SHOW/DESCRIBEstatements that the V2 parser rejects (e.g. unquoted SHOW TABLES LIKE %) are also routed back to the default pipeline, which falls back to the legacy engine.Additionally, added query-routing logging at both the SQL and PPL call sites for traceability when a query is routed to the analytics engine.
Related Issues
Part of #5248
Check List
--signoffor-s.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.