-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expose Druid functions in INFORMATION_SCHEMA.ROUTINES
table.
#14378
Conversation
I'm wondering why is not the IMO for boolean type, it would be more simplier and intuitive for user to filter out aggregator functions like select * from ROUTINES where IS_AGGREGATOR |
Good question, @FrankChen021. I wondered the same :) |
OK, let's keep it consistent with existing designs. |
sql/src/main/java/org/apache/druid/sql/calcite/schema/InformationSchema.java
Outdated
Show resolved
Hide resolved
sql/src/main/java/org/apache/druid/sql/calcite/schema/InformationSchema.java
Outdated
Show resolved
Hide resolved
sql/src/test/java/org/apache/druid/sql/calcite/CalciteQueryTest.java
Outdated
Show resolved
Hide resolved
sql/src/test/java/org/apache/druid/sql/calcite/schema/InformationSchemaTest.java
Outdated
Show resolved
Hide resolved
sql/src/test/java/org/apache/druid/sql/calcite/schema/InformationSchemaTest.java
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
This PR adds a new table
INFORMATION_SCHEMA.ROUTINES
. Resolves #14346.Description
The implementation currently exposes information about all functions in
INFORMATION_SCHEMA.ROUTINES
. The table contains the following columns:Since Calcite is the source of truth for all the registered functions, including ones loaded through custom extensions, the implementation uses the Calcite's operator table to extract this information at runtime.
A preview of the table from the Druid console:
Release note
Expose Druid functions via
INFORMATION_SCHEMA.ROUTINES
table.Key changed/added classes in this PR
InformationSchema.java
DruidOperatorTable.java
InformationSchemaTest.java
DruidOperatorTableTest.java
This PR has: