diff options
author | Matei Zaharia <matei@databricks.com> | 2014-01-22 14:05:48 -0800 |
---|---|---|
committer | Matei Zaharia <matei@databricks.com> | 2014-01-22 14:05:48 -0800 |
commit | 5bcfd798117e8617e604c1dd3b5c9b67e83100bb (patch) | |
tree | 36d124e42008469cc5a707e1c65598bc46f852f2 | |
parent | d009b17d137edf2f1b9da04254e55fb7455faa3d (diff) | |
parent | 19da82c50f1188a1d9949cd7df15b1541f3fd1e9 (diff) | |
download | spark-5bcfd798117e8617e604c1dd3b5c9b67e83100bb.tar.gz spark-5bcfd798117e8617e604c1dd3b5c9b67e83100bb.tar.bz2 spark-5bcfd798117e8617e604c1dd3b5c9b67e83100bb.zip |
Merge pull request #493 from kayousterhout/double_add
Fixed bug where task set managers are added to queue twice
@mateiz can you verify that this is a bug and wasn't intentional? (https://github.com/apache/incubator-spark/commit/90a04dab8d9a2a9a372cea7cdf46cc0fd0f2f76c#diff-7fa4f84a961750c374f2120ca70e96edR551)
This bug leads to a small performance hit because task
set managers will get offered each rejected resource
offer twice, but doesn't lead to any incorrect functionality.
Thanks to @hdc1112 for pointing this out.
-rw-r--r-- | core/src/main/scala/org/apache/spark/scheduler/TaskSetManager.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/src/main/scala/org/apache/spark/scheduler/TaskSetManager.scala b/core/src/main/scala/org/apache/spark/scheduler/TaskSetManager.scala index b9ce94be4b..e91470800c 100644 --- a/core/src/main/scala/org/apache/spark/scheduler/TaskSetManager.scala +++ b/core/src/main/scala/org/apache/spark/scheduler/TaskSetManager.scala @@ -592,7 +592,7 @@ private[spark] class TaskSetManager( override def removeSchedulable(schedulable: Schedulable) {} override def getSortedTaskSetQueue(): ArrayBuffer[TaskSetManager] = { - var sortedTaskSetQueue = ArrayBuffer[TaskSetManager](this) + var sortedTaskSetQueue = new ArrayBuffer[TaskSetManager]() sortedTaskSetQueue += this sortedTaskSetQueue } |