You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@linkis.apache.org by GitBox <gi...@apache.org> on 2023/01/15 08:38:58 UTC

[GitHub] [linkis] peacewong commented on a diff in pull request #4033: Add new api and fix spark collect_set result

peacewong commented on code in PR #4033:
URL: https://github.com/apache/linkis/pull/4033#discussion_r1070530910


##########
linkis-commons/linkis-common/src/main/scala/org/apache/linkis/common/conf/Configuration.scala:
##########
@@ -90,4 +95,24 @@ object Configuration extends Logging {
     linkisHome
   }
 
+  def isAdmin(username: String): Boolean = {
+    val adminUsers = GOVERNANCE_STATION_ADMIN.getHotValue.split(",")
+    adminUsers.exists(username.equalsIgnoreCase)
+  }
+
+  def isNotAdmin(username: String): Boolean = {
+    return !isAdmin(username)

Review Comment:
   should remove return



##########
linkis-computation-governance/linkis-entrance/src/main/scala/org/apache/linkis/entrance/timeout/JobTimeoutManager.scala:
##########
@@ -143,7 +143,7 @@ class JobTimeoutManager extends Logging {
 
     },
     0,
-    timeoutScanInterval,
+    EntranceConfiguration.TIMEOUT_SCAN_INTERVAL.getHotValue(),

Review Comment:
   should use getValue, for only invoke once



-- 
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@linkis.apache.org

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


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