Repository: spark
Updated Branches:
  refs/heads/branch-1.4 11a4b30d1 -> 8938a7489


[SPARK-7962] [MESOS] Fix master url parsing in rest submission client.

Only parse standalone master url when master url starts with spark://

Author: Timothy Chen <tnac...@gmail.com>

Closes #6517 from tnachen/fix_mesos_client and squashes the following commits:

61a1198 [Timothy Chen] Fix master url parsing in rest submission client.

(cherry picked from commit 78657d53d71b9d3e86b675cc519868f99e2ffa01)
Signed-off-by: Andrew Or <and...@databricks.com>


Project: http://git-wip-us.apache.org/repos/asf/spark/repo
Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/8938a748
Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/8938a748
Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/8938a748

Branch: refs/heads/branch-1.4
Commit: 8938a74893c29eb6d946541138428c4f75e8dc30
Parents: 11a4b30
Author: Timothy Chen <tnac...@gmail.com>
Authored: Fri May 29 23:56:18 2015 -0700
Committer: Andrew Or <and...@databricks.com>
Committed: Fri May 29 23:56:27 2015 -0700

----------------------------------------------------------------------
 .../org/apache/spark/deploy/rest/RestSubmissionClient.scala    | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/spark/blob/8938a748/core/src/main/scala/org/apache/spark/deploy/rest/RestSubmissionClient.scala
----------------------------------------------------------------------
diff --git 
a/core/src/main/scala/org/apache/spark/deploy/rest/RestSubmissionClient.scala 
b/core/src/main/scala/org/apache/spark/deploy/rest/RestSubmissionClient.scala
index 6078f50..1fe9563 100644
--- 
a/core/src/main/scala/org/apache/spark/deploy/rest/RestSubmissionClient.scala
+++ 
b/core/src/main/scala/org/apache/spark/deploy/rest/RestSubmissionClient.scala
@@ -57,7 +57,11 @@ private[spark] class RestSubmissionClient(master: String) 
extends Logging {
 
   private val supportedMasterPrefixes = Seq("spark://", "mesos://")
 
-  private val masters: Array[String] = Utils.parseStandaloneMasterUrls(master)
+  private val masters: Array[String] = if (master.startsWith("spark://")) {
+    Utils.parseStandaloneMasterUrls(master)
+  } else {
+    Array(master)
+  }
 
   // Set of masters that lost contact with us, used to keep track of
   // whether there are masters still alive for us to communicate with


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@spark.apache.org
For additional commands, e-mail: commits-h...@spark.apache.org

Reply via email to