squito commented on a change in pull request #24497:
[SPARK-11334][CORE][FOLLOWUP] Fix bug in Executor allocation manager in running
tasks calculation
URL: https://github.com/apache/spark/pull/24497#discussion_r280147031
##########
File path: core/src/main/scala/org/apache/spark/ExecutorAllocationManager.scala
##########
@@ -696,6 +699,7 @@ private[spark] class ExecutorAllocationManager(
allocationManager.synchronized {
stageIdToNumTasks -= stageId
stageIdToNumRunningTask -= stageId
+ activeStageIdToStageAttemptId -= stageId
Review comment:
I think this is OK. There aren't great names for the various status of a
stage. There may be multiple attempts with running tasks (lets call those
"running attempts"), but only one in a non-zombie state, which can continue to
submit more tasks (lets call that the "active attempt"). The scheduler sends a
StageCompleted as soon as a taskset goes from "active" to just "running",
before it submits another active attempt.
https://github.com/apache/spark/blob/9623420b77d81677b3fc5f055e6f521274e9caef/core/src/main/scala/org/apache/spark/scheduler/DAGScheduler.scala#L1516
So you should always see a StageCompleted before another StageSubmitted for
the same stage.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]