aboutsummaryrefslogtreecommitdiff
path: root/yarn
diff options
context:
space:
mode:
Diffstat (limited to 'yarn')
-rw-r--r--yarn/src/main/scala/org/apache/spark/scheduler/cluster/YarnSchedulerBackend.scala3
1 files changed, 3 insertions, 0 deletions
diff --git a/yarn/src/main/scala/org/apache/spark/scheduler/cluster/YarnSchedulerBackend.scala b/yarn/src/main/scala/org/apache/spark/scheduler/cluster/YarnSchedulerBackend.scala
index 1431bceb25..ca26277b50 100644
--- a/yarn/src/main/scala/org/apache/spark/scheduler/cluster/YarnSchedulerBackend.scala
+++ b/yarn/src/main/scala/org/apache/spark/scheduler/cluster/YarnSchedulerBackend.scala
@@ -83,6 +83,9 @@ private[spark] abstract class YarnSchedulerBackend(
override def stop(): Unit = {
try {
+ // SPARK-12009: To prevent Yarn allocator from requesting backup for the executors which
+ // was Stopped by SchedulerBackend.
+ requestTotalExecutors(0, 0, Map.empty)
super.stop()
} finally {
services.stop()