Github user vanzin commented on a diff in the pull request: https://github.com/apache/spark/pull/11229#discussion_r53368347 --- Diff: core/src/main/scala/org/apache/spark/SparkConf.scala --- @@ -503,6 +503,23 @@ class SparkConf(loadDefaults: Boolean) extends Cloneable with Logging { set("spark.executor.instances", value) } } + + if (contains("spark.master") && get("spark.master").startsWith("yarn")) { + val warning = s"spark.master ${get("spark.master")} is deprecated in Spark 2.0+, please " + + "instead use \"yarn\" with specified deploy mode." + + get("spark.master") match { + case "yarn-cluster" | "yarn-standalone" => + logWarning(warning) + set("spark.master", "yarn") + set("spark.submit.deployMode", "cluster") + case "yarn-client" => + logWarning(warning) + set("spark.master", "yarn") + set("spark.submit.deployMode", "client") + case _ => Unit --- End diff -- nit: `Unit` is not necessary here.
--- 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 infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org