You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/09/27 22:01:12 UTC
[GitHub] [spark] huaxingao opened a new pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
huaxingao opened a new pull request #34121:
URL: https://github.com/apache/spark/pull/34121
### What changes were proposed in this pull request?
Migrate `CreateFunctionStatement` to v2 command framework
### Why are the changes needed?
Migrate to the standard V2 framework
### Does this PR introduce _any_ user-facing change?
No
### How was this patch tested?
Existing tests
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-936998051
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48400/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935227292
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48374/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r717187979
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -451,7 +451,7 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
val funcIdentifier = identifier.asFunctionIdentifier
DropFunctionCommand(funcIdentifier.database, funcIdentifier.funcName, ifExists, isTemp)
- case CreateFunctionStatement(nameParts,
+ case CreateFunction(UnresolvedDBObjectName(nameParts, _),
Review comment:
I think we should follow `CreateNamespace` and match `ResolvedDBObjectName(catalog, name)` with `if isSessionCatalog(catalog)`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] huaxingao commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
huaxingao commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928473733
cc @cloud-fan @viirya
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] huaxingao commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
huaxingao commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928473733
cc @cloud-fan @viirya
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] huaxingao commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
huaxingao commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930704332
@cloud-fan Please take one more look? Thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930615905
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143725/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930408074
**[Test build #143725 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143725/testReport)** for PR 34121 at commit [`cc7414c`](https://github.com/apache/spark/commit/cc7414cf3f6537143d4a0296503cebc3b93ee00d).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929845159
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48214/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-936785506
**[Test build #143888 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143888/testReport)** for PR 34121 at commit [`b80816c`](https://github.com/apache/spark/commit/b80816c44e6ede8decf139c90227a9003881b1c1).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-938488951
thanks, merging to master!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] dohongdayi commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
dohongdayi commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r725424352
##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala
##########
@@ -4469,13 +4469,23 @@ class AstBuilder extends SqlBaseBaseVisitor[AnyRef] with SQLConfHelper with Logg
}
val functionIdentifier = visitMultipartIdentifier(ctx.multipartIdentifier)
- CreateFunctionStatement(
- functionIdentifier,
- string(ctx.className),
- resources.toSeq,
- ctx.TEMPORARY != null,
- ctx.EXISTS != null,
- ctx.REPLACE != null)
+ if (ctx.TEMPORARY != null) {
+ CreateTempFunction(
+ functionIdentifier,
+ string(ctx.className),
+ resources.toSeq,
+ ctx.EXISTS != null,
+ ctx.REPLACE != null)
+ } else {
+ CreateFunction(
+ UnresolvedDBObjectName(
+ functionIdentifier,
+ isNamespace = true),
Review comment:
I'm also dawned on now, what a favourite detail !
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929719190
**[Test build #143689 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143689/testReport)** for PR 34121 at commit [`81ae2dc`](https://github.com/apache/spark/commit/81ae2dcbc646f0b02d409adf26f9888d7fd13266).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928491216
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r717297303
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -451,31 +451,34 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
val funcIdentifier = identifier.asFunctionIdentifier
DropFunctionCommand(funcIdentifier.database, funcIdentifier.funcName, ifExists, isTemp)
- case CreateFunctionStatement(nameParts,
- className, resources, isTemp, ignoreIfExists, replace) =>
- if (isTemp) {
- // temp func doesn't belong to any catalog and we shouldn't resolve catalog in the name.
- val database = if (nameParts.length > 2) {
- throw QueryCompilationErrors.unsupportedFunctionNameError(nameParts.quoted)
- } else if (nameParts.length == 2) {
- Some(nameParts.head)
- } else {
- None
- }
- CreateFunctionCommand(
- database,
- nameParts.last,
- className,
- resources,
- isTemp,
- ignoreIfExists,
- replace)
+ case CreateTempFunction(nameParts, className, resources, ignoreIfExists, replace) =>
+ // temp func doesn't belong to any catalog and we shouldn't resolve catalog in the name.
+ val database = if (nameParts.length > 2) {
+ throw QueryCompilationErrors.unsupportedFunctionNameError(nameParts.quoted)
+ } else if (nameParts.length == 2) {
+ Some(nameParts.head)
} else {
- val FunctionIdentifier(function, database) =
- parseSessionCatalogFunctionIdentifier(nameParts)
- CreateFunctionCommand(database, function, className, resources, isTemp, ignoreIfExists,
- replace)
+ None
}
+ CreateFunctionCommand(
+ database,
+ nameParts.last,
+ className,
+ resources,
+ true,
+ ignoreIfExists,
+ replace)
+
+ case CreateFunction(ResolvedDBObjectName(catalog, name),
+ className, resources, ignoreIfExists, replace) if isSessionCatalog(catalog) =>
+ CreateFunctionCommand(
+ Some(catalog.name),
Review comment:
this is catalog name, not database name
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929754078
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48204/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928685998
**[Test build #143659 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143659/testReport)** for PR 34121 at commit [`d001c9f`](https://github.com/apache/spark/commit/d001c9fe9e6524ca4d6e24a8937ad25b1d166184).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds the following public classes _(experimental)_:
* `case class CreateFunction(`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928491216
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930498136
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48236/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928491216
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48172/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929754078
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929719190
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929843982
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143689/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935457065
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143861/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929719190
**[Test build #143689 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143689/testReport)** for PR 34121 at commit [`81ae2dc`](https://github.com/apache/spark/commit/81ae2dcbc646f0b02d409adf26f9888d7fd13266).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928917192
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48182/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928698061
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143659/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930602852
**[Test build #143725 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143725/testReport)** for PR 34121 at commit [`cc7414c`](https://github.com/apache/spark/commit/cc7414cf3f6537143d4a0296503cebc3b93ee00d).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds no public classes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r723029023
##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/connector/catalog/LookupCatalog.scala
##########
@@ -92,6 +92,31 @@ private[sql] trait LookupCatalog extends Logging {
}
}
+ object CatalogAndNamespaceForIdentifier {
Review comment:
what's the difference between this and CatalogAndIdentifier ?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928356625
**[Test build #143659 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143659/testReport)** for PR 34121 at commit [`d001c9f`](https://github.com/apache/spark/commit/d001c9fe9e6524ca4d6e24a8937ad25b1d166184).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929754078
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] huaxingao commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
huaxingao commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r722392789
##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala
##########
@@ -4469,13 +4469,23 @@ class AstBuilder extends SqlBaseBaseVisitor[AnyRef] with SQLConfHelper with Logg
}
val functionIdentifier = visitMultipartIdentifier(ctx.multipartIdentifier)
- CreateFunctionStatement(
- functionIdentifier,
- string(ctx.className),
- resources.toSeq,
- ctx.TEMPORARY != null,
- ctx.EXISTS != null,
- ctx.REPLACE != null)
+ if (ctx.TEMPORARY != null) {
+ CreateTempFunction(
+ functionIdentifier,
+ string(ctx.className),
+ resources.toSeq,
+ ctx.EXISTS != null,
+ ctx.REPLACE != null)
+ } else {
+ CreateFunction(
+ UnresolvedDBObjectName(
+ functionIdentifier,
+ isNamespace = true),
Review comment:
That's where I got confused. `UnresolvedDBObjectName` is resolved to `ResolvedDBObjectName` only when `isNamespace = true`?
https://github.com/apache/spark/blob/master/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveCatalogs.scala#L34
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928698061
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143659/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r717188301
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -451,7 +451,7 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
val funcIdentifier = identifier.asFunctionIdentifier
DropFunctionCommand(funcIdentifier.database, funcIdentifier.funcName, ifExists, isTemp)
- case CreateFunctionStatement(nameParts,
+ case CreateFunction(UnresolvedDBObjectName(nameParts, _),
Review comment:
let's also add a test that for `CREATE FUNCTION a.b.c`, we should throw a proper error saying that creating function is not supported in v2 catalog.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928892832
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48182/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928356625
**[Test build #143659 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143659/testReport)** for PR 34121 at commit [`d001c9f`](https://github.com/apache/spark/commit/d001c9fe9e6524ca4d6e24a8937ad25b1d166184).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930408074
**[Test build #143725 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143725/testReport)** for PR 34121 at commit [`cc7414c`](https://github.com/apache/spark/commit/cc7414cf3f6537143d4a0296503cebc3b93ee00d).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929829415
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48214/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928356625
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930512973
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48236/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929754039
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48204/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929808941
**[Test build #143699 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143699/testReport)** for PR 34121 at commit [`c8d27aa`](https://github.com/apache/spark/commit/c8d27aa5112f78c82732231b86f588c922615ce6).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929845186
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r721993275
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -483,6 +469,30 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
RefreshFunctionCommand(funcIdentifier.database, funcIdentifier.funcName)
}
+ private def callCreateFunctionCommand(
Review comment:
nit: `convertToV1CreateFunction`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928859951
**[Test build #143670 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143670/testReport)** for PR 34121 at commit [`fa2f064`](https://github.com/apache/spark/commit/fa2f064fdb2910ff3bc5205f251292f98dc1f4f4).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928905789
**[Test build #143670 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143670/testReport)** for PR 34121 at commit [`fa2f064`](https://github.com/apache/spark/commit/fa2f064fdb2910ff3bc5205f251292f98dc1f4f4).
* This patch **fails Spark unit tests**.
* This patch merges cleanly.
* This patch adds the following public classes _(experimental)_:
* `case class CreateTempFunction(`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-936998051
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48400/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r717187979
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -451,7 +451,7 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
val funcIdentifier = identifier.asFunctionIdentifier
DropFunctionCommand(funcIdentifier.database, funcIdentifier.funcName, ifExists, isTemp)
- case CreateFunctionStatement(nameParts,
+ case CreateFunction(UnresolvedDBObjectName(nameParts, _),
Review comment:
I think we should follow `CreateNamespace` and match `ResolvedDBObjectName(catalog, name)` with `if isSessionCatalog(catalog)`
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -451,7 +451,7 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
val funcIdentifier = identifier.asFunctionIdentifier
DropFunctionCommand(funcIdentifier.database, funcIdentifier.funcName, ifExists, isTemp)
- case CreateFunctionStatement(nameParts,
+ case CreateFunction(UnresolvedDBObjectName(nameParts, _),
Review comment:
let's also add a test that for `CREATE FUNCTION a.b.c`, we should throw a proper error saying that creating function is not supported in v2 catalog.
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -451,31 +451,34 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
val funcIdentifier = identifier.asFunctionIdentifier
DropFunctionCommand(funcIdentifier.database, funcIdentifier.funcName, ifExists, isTemp)
- case CreateFunctionStatement(nameParts,
- className, resources, isTemp, ignoreIfExists, replace) =>
- if (isTemp) {
- // temp func doesn't belong to any catalog and we shouldn't resolve catalog in the name.
- val database = if (nameParts.length > 2) {
- throw QueryCompilationErrors.unsupportedFunctionNameError(nameParts.quoted)
- } else if (nameParts.length == 2) {
- Some(nameParts.head)
- } else {
- None
- }
- CreateFunctionCommand(
- database,
- nameParts.last,
- className,
- resources,
- isTemp,
- ignoreIfExists,
- replace)
+ case CreateTempFunction(nameParts, className, resources, ignoreIfExists, replace) =>
+ // temp func doesn't belong to any catalog and we shouldn't resolve catalog in the name.
+ val database = if (nameParts.length > 2) {
+ throw QueryCompilationErrors.unsupportedFunctionNameError(nameParts.quoted)
+ } else if (nameParts.length == 2) {
+ Some(nameParts.head)
} else {
- val FunctionIdentifier(function, database) =
- parseSessionCatalogFunctionIdentifier(nameParts)
- CreateFunctionCommand(database, function, className, resources, isTemp, ignoreIfExists,
- replace)
+ None
}
+ CreateFunctionCommand(
+ database,
+ nameParts.last,
+ className,
+ resources,
+ true,
+ ignoreIfExists,
+ replace)
+
+ case CreateFunction(ResolvedDBObjectName(catalog, name),
+ className, resources, ignoreIfExists, replace) if isSessionCatalog(catalog) =>
+ CreateFunctionCommand(
+ Some(catalog.name),
Review comment:
this is catalog name, not database name
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935158227
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48374/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928356625
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928859951
**[Test build #143670 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143670/testReport)** for PR 34121 at commit [`fa2f064`](https://github.com/apache/spark/commit/fa2f064fdb2910ff3bc5205f251292f98dc1f4f4).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929840598
**[Test build #143689 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143689/testReport)** for PR 34121 at commit [`81ae2dc`](https://github.com/apache/spark/commit/81ae2dcbc646f0b02d409adf26f9888d7fd13266).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds no public classes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929882380
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143699/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930615905
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143725/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] huaxingao commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
huaxingao commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-938689606
Thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] huaxingao commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
huaxingao commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r722788805
##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala
##########
@@ -4469,13 +4469,23 @@ class AstBuilder extends SqlBaseBaseVisitor[AnyRef] with SQLConfHelper with Logg
}
val functionIdentifier = visitMultipartIdentifier(ctx.multipartIdentifier)
- CreateFunctionStatement(
- functionIdentifier,
- string(ctx.className),
- resources.toSeq,
- ctx.TEMPORARY != null,
- ctx.EXISTS != null,
- ctx.REPLACE != null)
+ if (ctx.TEMPORARY != null) {
+ CreateTempFunction(
+ functionIdentifier,
+ string(ctx.className),
+ resources.toSeq,
+ ctx.EXISTS != null,
+ ctx.REPLACE != null)
+ } else {
+ CreateFunction(
+ UnresolvedDBObjectName(
+ functionIdentifier,
+ isNamespace = true),
Review comment:
Never mind what I said earlier. I will give it one more try.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935108441
**[Test build #143861 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143861/testReport)** for PR 34121 at commit [`54d9056`](https://github.com/apache/spark/commit/54d9056870512fe2d5db8852e2a72bddb20ac06f).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] dohongdayi commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
dohongdayi commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r725424352
##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala
##########
@@ -4469,13 +4469,23 @@ class AstBuilder extends SqlBaseBaseVisitor[AnyRef] with SQLConfHelper with Logg
}
val functionIdentifier = visitMultipartIdentifier(ctx.multipartIdentifier)
- CreateFunctionStatement(
- functionIdentifier,
- string(ctx.className),
- resources.toSeq,
- ctx.TEMPORARY != null,
- ctx.EXISTS != null,
- ctx.REPLACE != null)
+ if (ctx.TEMPORARY != null) {
+ CreateTempFunction(
+ functionIdentifier,
+ string(ctx.className),
+ resources.toSeq,
+ ctx.EXISTS != null,
+ ctx.REPLACE != null)
+ } else {
+ CreateFunction(
+ UnresolvedDBObjectName(
+ functionIdentifier,
+ isNamespace = true),
Review comment:
I'm also dawned on now, what a favourite detail!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan closed pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan closed pull request #34121:
URL: https://github.com/apache/spark/pull/34121
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-936879805
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48400/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935457065
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143861/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935454776
**[Test build #143861 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143861/testReport)** for PR 34121 at commit [`54d9056`](https://github.com/apache/spark/commit/54d9056870512fe2d5db8852e2a72bddb20ac06f).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds no public classes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930512973
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48236/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-930453472
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48236/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929882380
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/143699/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] huaxingao commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
huaxingao commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r717208534
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -451,7 +451,7 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
val funcIdentifier = identifier.asFunctionIdentifier
DropFunctionCommand(funcIdentifier.database, funcIdentifier.funcName, ifExists, isTemp)
- case CreateFunctionStatement(nameParts,
+ case CreateFunction(UnresolvedDBObjectName(nameParts, _),
Review comment:
seems we have a test here https://github.com/apache/spark/blob/master/sql/core/src/test/scala/org/apache/spark/sql/connector/DataSourceV2SQLSuite.scala#L2213
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929737558
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48204/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r721992103
##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala
##########
@@ -4469,13 +4469,23 @@ class AstBuilder extends SqlBaseBaseVisitor[AnyRef] with SQLConfHelper with Logg
}
val functionIdentifier = visitMultipartIdentifier(ctx.multipartIdentifier)
- CreateFunctionStatement(
- functionIdentifier,
- string(ctx.className),
- resources.toSeq,
- ctx.TEMPORARY != null,
- ctx.EXISTS != null,
- ctx.REPLACE != null)
+ if (ctx.TEMPORARY != null) {
+ CreateTempFunction(
+ functionIdentifier,
+ string(ctx.className),
+ resources.toSeq,
+ ctx.EXISTS != null,
+ ctx.REPLACE != null)
+ } else {
+ CreateFunction(
+ UnresolvedDBObjectName(
+ functionIdentifier,
+ isNamespace = true),
Review comment:
why `isNamespace = true`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935230897
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48374/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] dohongdayi commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
dohongdayi commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r725424352
##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala
##########
@@ -4469,13 +4469,23 @@ class AstBuilder extends SqlBaseBaseVisitor[AnyRef] with SQLConfHelper with Logg
}
val functionIdentifier = visitMultipartIdentifier(ctx.multipartIdentifier)
- CreateFunctionStatement(
- functionIdentifier,
- string(ctx.className),
- resources.toSeq,
- ctx.TEMPORARY != null,
- ctx.EXISTS != null,
- ctx.REPLACE != null)
+ if (ctx.TEMPORARY != null) {
+ CreateTempFunction(
+ functionIdentifier,
+ string(ctx.className),
+ resources.toSeq,
+ ctx.EXISTS != null,
+ ctx.REPLACE != null)
+ } else {
+ CreateFunction(
+ UnresolvedDBObjectName(
+ functionIdentifier,
+ isNamespace = true),
Review comment:
I'm also dawned on now, what a memorable detail!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935230897
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48374/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928921418
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928413679
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48172/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-936962424
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48400/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-935108441
**[Test build #143861 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143861/testReport)** for PR 34121 at commit [`54d9056`](https://github.com/apache/spark/commit/54d9056870512fe2d5db8852e2a72bddb20ac06f).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929882055
**[Test build #143699 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143699/testReport)** for PR 34121 at commit [`c8d27aa`](https://github.com/apache/spark/commit/c8d27aa5112f78c82732231b86f588c922615ce6).
* This patch **fails Spark unit tests**.
* This patch merges cleanly.
* This patch adds no public classes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928463147
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/48172/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929808941
**[Test build #143699 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/143699/testReport)** for PR 34121 at commit [`c8d27aa`](https://github.com/apache/spark/commit/c8d27aa5112f78c82732231b86f588c922615ce6).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929719190
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929754078
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48204/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928491216
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48172/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-929845186
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/48214/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] huaxingao commented on a change in pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
huaxingao commented on a change in pull request #34121:
URL: https://github.com/apache/spark/pull/34121#discussion_r717208534
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -451,7 +451,7 @@ class ResolveSessionCatalog(val catalogManager: CatalogManager)
val funcIdentifier = identifier.asFunctionIdentifier
DropFunctionCommand(funcIdentifier.database, funcIdentifier.funcName, ifExists, isTemp)
- case CreateFunctionStatement(nameParts,
+ case CreateFunction(UnresolvedDBObjectName(nameParts, _),
Review comment:
seems we have a test here https://github.com/apache/spark/blob/master/sql/core/src/test/scala/org/apache/spark/sql/connector/DataSourceV2SQLSuite.scala#L2213
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34121: [SPARK-36868][SQL] Migrate CreateFunctionStatement to v2 command framework
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34121:
URL: https://github.com/apache/spark/pull/34121#issuecomment-928921418
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org