Github user andrewor14 commented on a diff in the pull request:
https://github.com/apache/spark/pull/6817#discussion_r36575654
--- Diff:
core/src/main/scala/org/apache/spark/ExecutorAllocationManager.scala ---
@@ -599,15 +599,6 @@ private[spark] class ExecutorAllocationManager(
// If this is the last pending task, mark the scheduler queue as
empty
stageIdToTaskIndices.getOrElseUpdate(stageId, new
mutable.HashSet[Int]) += taskIndex
- val numTasksScheduled = stageIdToTaskIndices(stageId).size
- val numTasksTotal = stageIdToNumTasks.getOrElse(stageId, -1)
- if (numTasksScheduled == numTasksTotal) {
- // No more pending tasks for this stage
- stageIdToNumTasks -= stageId
- if (stageIdToNumTasks.isEmpty) {
- allocationManager.onSchedulerQueueEmpty()
--- End diff --
It's not correct to remove this entire block. I was referring specifically
to
[L606](https://github.com/apache/spark/blob/c564b27447ed99e55b359b3df1d586d5766b85ea/core/src/main/scala/org/apache/spark/ExecutorAllocationManager.scala#L606)
of the old code when I said delete it.
We still need to call `onSchedulerQueueEmpty` because this says all the
tasks have been scheduled so there are no more pending tasks, which means we
don't have to request more executors.
---
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 [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]