线程池execute线程后,用Thread.currentThread().getName() 获取不到本来的名字。
解决办法:
在线程的方法里面,用this.getName() 即可。
线程池无法获取到线程的名字
猜你喜欢
转载自blog.csdn.net/enthan809882/article/details/104243686
今日推荐
周排行