【发布时间】:2013-11-23 13:11:21
【问题描述】:
我有这三个问题:
1.Is there a way to clean ThreadLocal's data when the Thread's task is done.
2.How about when the thread is in ThreadPool.
3.How can I know a Thread is reused and given back to the ThreadPool.
【问题讨论】:
-
你指的是什么线程池?这些? docs.oracle.com/javase/tutorial/essential/concurrency/…
-
@isnot2bad 我不知道它是什么线程池。它只是一个池保存线程。
-
我的意思是,你是使用 JDK 的线程池,还是使用任何其他第三方库?
-
@isnot2bad 这不是一个特定的池。可能来自 JDK 或其他第三方库。
标签: java multithreading threadpool