-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Add a native function namespace manager #23358
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
Add a native function namespace manager #23358
Conversation
49d3b9d to
5ed5a18
Compare
bcb09bc to
ce7ca4b
Compare
steveburnett
left a comment
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.
LGTM! (docs)
Pull branch, new local doc build, the doc looks good. Thanks!
4d00991 to
c3ed29f
Compare
steveburnett
left a comment
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.
LGTM! (docs)
Pull updated branch, new local doc build, doc looks good. Thanks!
3fde055 to
ebfa361
Compare
f203d25 to
88e1152
Compare
tdcmeehan
left a comment
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.
Just some initial comments
presto-common/src/main/java/com/facebook/presto/common/type/TypeSignature.java
Outdated
Show resolved
Hide resolved
...n/java/com/facebook/presto/functionNamespace/AbstractSqlInvokedFunctionNamespaceManager.java
Outdated
Show resolved
Hide resolved
...n/java/com/facebook/presto/functionNamespace/AbstractSqlInvokedFunctionNamespaceManager.java
Show resolved
Hide resolved
presto-main/src/main/java/com/facebook/presto/metadata/FunctionAndTypeManager.java
Outdated
Show resolved
Hide resolved
tdcmeehan
left a comment
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.
Refactored qualifyObjectName from static to instance method ✅
tdcmeehan
left a comment
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.
Add utility functions to resolve intermediate type in aggregate funct… ❓
Thank you for the really extensive tests for this utility. I think the tests should be broken down to the various different types, because the tests are rather large.
tdcmeehan
left a comment
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.
[native] Fix bug when handling multiple params and no params aggregat… ❓
Can you help me understand when this bug manifests? Is there any way to add a unit test for it?
presto-spi/src/main/java/com/facebook/presto/spi/ConnectorSystemConfig.java
Outdated
Show resolved
Hide resolved
d7dec93 to
c4fe9ec
Compare
c4fe9ec to
38edeb3
Compare
| folly::split( | ||
| '.', | ||
| prestoDefaultNamespacePrefix, | ||
| prestoDefaultNamespacePrefixParts, |
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.
Add CHECK that prestoDefaultNamespacePrefixParts has only 2 parts.
aditi-pandit
left a comment
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.
@pdabre12 : Have 2 minor comments.
|
|
||
| std::vector<std::string> parts; | ||
| folly::split('.', functionName, parts, true); | ||
| if ((parts.size() != 3) || |
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.
Should this be a check instead ? Are there functions that don't follow since (since you added all the built-ins with prefixes) ?
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.
All the functions should have a prefix. Added the check, thanks.
| #include "presto_cpp/presto_protocol/core/presto_protocol_core.h" | ||
| #include "velox/core/Expressions.h" | ||
|
|
||
| namespace { |
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.
Consider moving this to presto_cpp/main/common/Utils.h
38edeb3 to
63b7d00
Compare
aditi-pandit
left a comment
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.
Thanks @pdabre12
Description
Adds a native function namespace manager
Motivation and Context
To help resolve : #23000
Impact
Test Plan
Unit and end-to-end tests. More comprehensive end-to-end tests will be written in the future.
Contributor checklist
Depends on : #23671