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

    https://github.com/apache/spark/pull/20327#discussion_r163491802
  
    --- Diff: core/src/main/scala/org/apache/spark/SparkContext.scala ---
    @@ -385,7 +386,13 @@ class SparkContext(config: SparkConf) extends Logging {
     
         // Set Spark driver host and port system properties. This explicitly 
sets the configuration
         // instead of relying on the default value of the config constant.
    -    _conf.set(DRIVER_HOST_ADDRESS, _conf.get(DRIVER_HOST_ADDRESS))
    +    _conf.set(DRIVER_HOST_ADDRESS,
    +      if (master == "yarn") {
    +        System.getenv(ApplicationConstants.Environment.NM_HOST.toString)
    --- End diff --
    
    The changes here will also affect yarn client mode.


---

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

Reply via email to