Github user vanzin commented on a diff in the pull request:
https://github.com/apache/spark/pull/1256#discussion_r14843448
--- Diff:
core/src/main/scala/org/apache/spark/deploy/master/MasterArguments.scala ---
@@ -38,19 +39,24 @@ private[spark] class MasterArguments(args:
Array[String], conf: SparkConf) {
if (System.getenv("SPARK_MASTER_WEBUI_PORT") != null) {
webUiPort = System.getenv("SPARK_MASTER_WEBUI_PORT").toInt
}
+
+ parse(args.toList)
+
+ // Use common defaults file, if not specified by user
+ propertiesFile =
Option(propertiesFile).getOrElse(Utils.getDefaultSparkPropertiesFile.orNull)
+ Option(propertiesFile).foreach(f => conf.loadPropertiesFromFile(f))
+
if (conf.contains("master.ui.port")) {
webUiPort = conf.get("master.ui.port").toInt
}
- parse(args.toList)
-
def parse(args: List[String]): Unit = args match {
case ("--ip" | "-i") :: value :: tail =>
Utils.checkHost(value, "ip no longer supported, please use hostname
" + value)
host = value
parse(tail)
- case ("--host" | "-h") :: value :: tail =>
--- End diff --
I see what you're doing, but it seems like the previous code will treat
`-h` as `--host` and not as `--help`, so with your change, if anyone is relying
on that, things might break.
---
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.
---