vanzin commented on a change in pull request #141: [LIVY-551] Add "doAs" impersonation support URL: https://github.com/apache/incubator-livy/pull/141#discussion_r251675173
########## File path: server/src/main/scala/org/apache/livy/server/batch/BatchSession.scala ########## @@ -55,12 +54,11 @@ object BatchSession extends Logging { id: Int, request: CreateBatchRequest, livyConf: LivyConf, - accessManager: AccessManager, owner: String, + impersonatedUser: Option[String], sessionStore: SessionStore, mockApp: Option[SparkApp] = None): BatchSession = { val appTag = s"livy-batch-$id-${Random.alphanumeric.take(8).mkString}" - val impersonatedUser = accessManager.checkImpersonation(request.proxyUser, owner, livyConf) Review comment: It's just moving the check to the servlet, which happens before this is called. Are you worried that another call site might be added and we forget about the access check? ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services