- 博客(2)
- 收藏
- 关注
原创 Java8 ReentrantLock Condition运用
Java8 ReentrantLock Condition在LinkedBlockingQueue中的使用场景1.持有的锁2.插入元素3.获取元素4.经验总结在LinkedBlockingQueue中的使用场景下面以LinkedBlockingQueue为例,分析ReentrantLock和Condition的作用。1.持有的锁/** Lock held by take, poll, etc */private final ReentrantLock takeLock = new Reentra
2020-12-29 14:32:48
2254
4
原创 Java8 ThreadPoolExecutor线程池分析
ThreadPoolExecutor构造函数逻辑分析构造函数public ThreadPoolExecutor(int corePoolSize, int maximumPoolSize, long keepAliveTime, TimeUnit unit, BlockingQueue<Run
2020-12-28 18:09:36
170
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅