wuyi created SPARK-54861:
----------------------------
Summary: Unset task thread name when the task completes
Key: SPARK-54861
URL: https://issues.apache.org/jira/browse/SPARK-54861
Project: Spark
Issue Type: Task
Components: Spark Core
Affects Versions: 3.5.7, 4.0.1, 4.1.0
Reporter: wuyi
Currently, when a task completes, the [task thread
name|https://github.com/apache/spark/blob/master/core/src/main/scala/org/apache/spark/executor/Executor.scala#L642]
remains unchanged until a new task launched overrides the original name. And
this can be misleading when we look into the task stacktrace for the completed
task as the task thread is actually idle for the new task rather than running
for some active task.
{code:java}
Executor task launch worker for task 0.0 in stage 0.0 (TID 0)" #64 TIMED_WAITING
[email protected]/jdk.internal.misc.Unsafe.park(Native Method)
- waiting on
java.util.concurrent.SynchronousQueue$TransferStack@4958b5c2
[email protected]/java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:252)
[email protected]/java.util.concurrent.SynchronousQueue$TransferStack.transfer(SynchronousQueue.java:401)
[email protected]/java.util.concurrent.SynchronousQueue.poll(SynchronousQueue.java:903)
[email protected]/java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1061)
[email protected]/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1122)
[email protected]/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
[email protected]/java.lang.Thread.run(Thread.java:840) {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]