spark-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From andrewo...@apache.org
Subject spark git commit: [SPARK-5691] Fixing wrong data structure lookup for dupe app registration
Date Mon, 09 Feb 2015 21:21:22 GMT
Repository: spark
Updated Branches:
  refs/heads/branch-1.2 4bad85485 -> 97541b22e


[SPARK-5691] Fixing wrong data structure lookup for dupe app registration

In Master's registerApplication method, it checks if the application had
already registered by examining the addressToWorker hash map. In reality,
it should refer to the addressToApp data structure, as this is what
really tracks which apps have been registered.


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

Branch: refs/heads/branch-1.2
Commit: 97541b22ea4a98ee8001f3069c1c4673c9582d78
Parents: 4bad854
Author: mcheah <mcheah@palantir.com>
Authored: Mon Feb 9 19:58:58 2015 +0100
Committer: Andrew Or <andrew@databricks.com>
Committed: Mon Feb 9 13:21:18 2015 -0800

----------------------------------------------------------------------
 core/src/main/scala/org/apache/spark/deploy/master/Master.scala | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/spark/blob/97541b22/core/src/main/scala/org/apache/spark/deploy/master/Master.scala
----------------------------------------------------------------------
diff --git a/core/src/main/scala/org/apache/spark/deploy/master/Master.scala b/core/src/main/scala/org/apache/spark/deploy/master/Master.scala
index 56169d2..5d20e84 100644
--- a/core/src/main/scala/org/apache/spark/deploy/master/Master.scala
+++ b/core/src/main/scala/org/apache/spark/deploy/master/Master.scala
@@ -640,7 +640,7 @@ private[spark] class Master(
 
   def registerApplication(app: ApplicationInfo): Unit = {
     val appAddress = app.driver.path.address
-    if (addressToWorker.contains(appAddress)) {
+    if (addressToApp.contains(appAddress)) {
       logInfo("Attempted to re-register application at same address: " + appAddress)
       return
     }


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


Mime
View raw message