Skip to content

Commit cf8b6cf

Browse files
author
Ashwin Shankar
committed
Stop counting preemption of executors as failure
1 parent 1712a7c commit cf8b6cf

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

yarn/src/main/scala/org/apache/spark/deploy/yarn/YarnAllocator.scala

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -373,7 +373,11 @@ private[yarn] class YarnAllocator(
373373
// Hadoop 2.2.X added a ContainerExitStatus we should switch to use
374374
// there are some exit status' we shouldn't necessarily count against us, but for
375375
// now I think its ok as none of the containers are expected to exit
376-
if (completedContainer.getExitStatus == -103) { // vmem limit exceeded
376+
if (completedContainer.getExitStatus == ContainerExitStatus.PREEMPTED) {
377+
logInfo("Container killed: " + containerId +
378+
". Exit status: " + completedContainer.getExitStatus +
379+
". Diagnostics: " + completedContainer.getDiagnostics)
380+
} else if (completedContainer.getExitStatus == -103) { // vmem limit exceeded
377381
logWarning(memLimitExceededLogMessage(
378382
completedContainer.getDiagnostics,
379383
VMEM_EXCEEDED_PATTERN))

0 commit comments

Comments
 (0)