Skip to content

Commit 46fb2f7

Browse files
committed
Just use new thread and set daemon since runInNewThread does a join we don't want.
1 parent 12e9e23 commit 46fb2f7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

core/src/main/scala/org/apache/spark/executor/CoarseGrainedExecutorBackend.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ private[spark] class CoarseGrainedExecutorBackend(
290290
// is viewed as acceptable to minimize introduction of any new locking structures in critical
291291
// code paths.
292292

293-
val shutdownThread = ThreadUtils.runInNewThread("wait-for-blocks-to-migrate") {
293+
val shutdownThread = new Thread("wait-for-blocks-to-migrate") {
294294
var lastTaskRunningTime = System.nanoTime()
295295
val sleep_time = 1000 // 1s
296296

@@ -321,7 +321,7 @@ private[spark] class CoarseGrainedExecutorBackend(
321321
lastTaskRunningTime = System.nanoTime()
322322
}
323323
}
324-
}
324+
}.setDaemon(true)
325325
logInfo("Will exit when finished decommissioning")
326326
// Return true since we are handling a signal
327327
true

0 commit comments

Comments
 (0)