Github user aarondav commented on a diff in the pull request:

    https://github.com/apache/spark/pull/621#discussion_r12252364
  
    --- Diff: 
core/src/main/scala/org/apache/spark/executor/CoarseGrainedExecutorBackend.scala
 ---
    @@ -94,25 +95,32 @@ private[spark] class CoarseGrainedExecutorBackend(
     
     private[spark] object CoarseGrainedExecutorBackend {
       def run(driverUrl: String, executorId: String, hostname: String, cores: 
Int,
    -          workerUrl: Option[String]) {
    -    // Debug code
    -    Utils.checkHost(hostname)
    -
    -    val conf = new SparkConf
    -    // Create a new ActorSystem to run the backend, because we can't 
create a SparkEnv / Executor
    -    // before getting started with all our system properties, etc
    -    val (actorSystem, boundPort) = 
AkkaUtils.createActorSystem("sparkExecutor", hostname, 0,
    -      indestructible = true, conf = conf, new SecurityManager(conf))
    -    // set it
    -    val sparkHostPort = hostname + ":" + boundPort
    -    actorSystem.actorOf(
    -      Props(classOf[CoarseGrainedExecutorBackend], driverUrl, executorId,
    -        sparkHostPort, cores),
    -      name = "Executor")
    -    workerUrl.foreach{ url =>
    -      actorSystem.actorOf(Props(classOf[WorkerWatcher], url), name = 
"WorkerWatcher")
    +    workerUrl: Option[String]) {
    +
    +    val sparkUser = 
Option(System.getenv("SPARK_USER")).getOrElse(SparkContext.SPARK_UNKNOWN_USER)
    --- End diff --
    
    I believe runAsUser is not actually used anywhere else. We can probably 
just make it intended for only this exact use-case to not confuse users with 
its over-generality until it's necessary.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to