From 18c4ee71e27189f5f3f4eb6bfc6ad8860aa254c6 Mon Sep 17 00:00:00 2001 From: CodingCat Date: Wed, 5 Feb 2014 22:08:47 -0800 Subject: [PATCH] Merge pull request #549 from CodingCat/deadcode_master. Closes #549. remove actorToWorker in master.scala, which is actually not used actorToWorker is actually not used in the code....just remove it Author: CodingCat == Merge branch commits == commit 52656c2d4bbf9abcd8bef65d454badb9cb14a32c Author: CodingCat Date: Thu Feb 6 00:28:26 2014 -0500 remove actorToWorker in master.scala, which is actually not used --- .../src/main/scala/org/apache/spark/deploy/master/Master.scala | 3 --- 1 file changed, 3 deletions(-) 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 380055728f..2ef167ffc0 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 @@ -54,7 +54,6 @@ private[spark] class Master(host: String, port: Int, webUiPort: Int) extends Act val workers = new HashSet[WorkerInfo] val idToWorker = new HashMap[String, WorkerInfo] - val actorToWorker = new HashMap[ActorRef, WorkerInfo] val addressToWorker = new HashMap[Address, WorkerInfo] val apps = new HashSet[ApplicationInfo] @@ -534,7 +533,6 @@ private[spark] class Master(host: String, port: Int, webUiPort: Int) extends Act workers += worker idToWorker(worker.id) = worker - actorToWorker(worker.actor) = worker addressToWorker(workerAddress) = worker true } @@ -543,7 +541,6 @@ private[spark] class Master(host: String, port: Int, webUiPort: Int) extends Act logInfo("Removing worker " + worker.id + " on " + worker.host + ":" + worker.port) worker.setState(WorkerState.DEAD) idToWorker -= worker.id - actorToWorker -= worker.actor addressToWorker -= worker.actor.path.address for (exec <- worker.executors.values) { logInfo("Telling app of lost executor: " + exec.id)