File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed 
core/src/main/scala/org/apache/spark/deploy/rest Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -408,6 +408,7 @@ private[spark] class RestSubmissionClient(master: String) extends Logging {
408408}
409409
410410private [spark] object  RestSubmissionClient  {
411+   private  val  BLACKLISTED_SPARK_ENV_VARS  =  Set (" SPARK_ENV_LOADED" " SPARK_HOME" " SPARK_CONF_DIR" 
411412  private  val  REPORT_DRIVER_STATUS_INTERVAL  =  1000 
412413  private  val  REPORT_DRIVER_STATUS_MAX_TRIES  =  10 
413414  val  PROTOCOL_VERSION  =  " v1" 
@@ -419,8 +420,7 @@ private[spark] object RestSubmissionClient {
419420    env.filterKeys { k => 
420421      //  SPARK_HOME and SPARK_CONF_DIR are filtered out because they are usually wrong
421422      //  on the remote machine (SPARK-12345) (SPARK-25934)
422-       (k.startsWith(" SPARK_" &&  k !=  " SPARK_ENV_LOADED" &&  k !=  " SPARK_HOME" 
423-         &&  k !=  " SPARK_CONF_DIR" ||  k.startsWith(" MESOS_" 
423+       (k.startsWith(" SPARK_" &&  ! BLACKLISTED_SPARK_ENV_VARS .contains(k)) ||  k.startsWith(" MESOS_" 
424424    }
425425  }
426426}
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments