Github user vanzin commented on the issue:

    https://github.com/apache/spark/pull/20645
  
    I like the functionality, not necessarily the implementation. Other configs 
would benefit from this, and having this functionality more easily available 
without having to change the call sites would make it more useful.
    
    I'm also not a big fan of "default" being used in the name. But can't 
really think of a better alternative at the moment.
    
    As far as implementation, I think building this into the `ConfigBuilder` 
code would be better. e.g. add a method where you can configure a property name 
for the "default" value, and when reading a property, both configs would be 
concatenated with some configurable separator. e.g., using your names:
    
    ```
    private[spark] val DRIVER_JAVA_OPTIONS =
       ConfigBuilder(SparkLauncher.DRIVER_EXTRA_JAVA_OPTIONS)
         .withDefaultConfig(SparkLauncher.DRIVER_DEFAULT_JAVA_OPTIONS, " ")
         .stringConf
        .createOptional
    ```
    
    And reading `DRIVER_JAVA_OPTIONS` would return the two configs, 
concatenated, separated by a space. Then you could use this for things like 
classpath, native libraries, and many others without having to change any of 
the code that reads those configs.


---

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

Reply via email to