modi95 commented on a change in pull request #25176: [SPARK-28417][CORE] Wrap 
File Glob Resolution in DoAs to use ProxyUser Credentials
URL: https://github.com/apache/spark/pull/25176#discussion_r304610316
 
 

 ##########
 File path: core/src/main/scala/org/apache/spark/deploy/SparkSubmit.scala
 ##########
 @@ -378,10 +378,24 @@ private[spark] class SparkSubmit extends Logging {
     }
 
     // Resolve glob path for different resources.
-    args.jars = Option(args.jars).map(resolveGlobPaths(_, hadoopConf)).orNull
-    args.files = Option(args.files).map(resolveGlobPaths(_, hadoopConf)).orNull
-    args.pyFiles = Option(args.pyFiles).map(resolveGlobPaths(_, 
hadoopConf)).orNull
-    args.archives = Option(args.archives).map(resolveGlobPaths(_, 
hadoopConf)).orNull
+    val proxyUser = if (args.proxyUser != null) {
+      UserGroupInformation.createProxyUser(args.proxyUser, 
UserGroupInformation.getCurrentUser)
 
 Review comment:
   I would love to stick to that standard! However I was not able to find an 
implementation of getCurrentUser that takes parameters and I wasn't able to 
find `getCurrentUser(hadoopConf)` in the repo - 
https://github.com/apache/spark/search?q=getCurrentUser&unscoped_q=getCurrentUser.
 Was I looking in the wrong place 🙂? 

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to