You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@kyuubi.apache.org by GitBox <gi...@apache.org> on 2022/10/15 12:27:15 UTC

[GitHub] [incubator-kyuubi] packyan commented on a diff in pull request #3593: [KYUUBI #3592] Spark SQL authz only consider permanent functions

packyan commented on code in PR #3593:
URL: https://github.com/apache/incubator-kyuubi/pull/3593#discussion_r996299922


##########
extensions/spark/kyuubi-spark-authz/src/main/scala/org/apache/kyuubi/plugin/spark/authz/PrivilegesBuilder.scala:
##########
@@ -386,7 +390,10 @@ object PrivilegesBuilder {
 
       case "DescribeFunctionCommand" =>
         val func = getPlanField[FunctionIdentifier]("functionName")
-        inputObjs += functionPrivileges(func.database.orNull, func.funcName)
+        val isTemp = spark.sessionState.catalog.isTemporaryFunction(func)

Review Comment:
   isTempFunction is not suitable for here, I have changed it to check the functioon is persistent or not, as built-in function is also not temporay, so generalizing a `isPersistentFunction` method is more reasonable?



-- 
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: notifications-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org