线程池原理和流程线程等待池,即线程队列BlockingQueue任务处理池,PoolWorker,即正在工作的Thread列表(HashSet<Worker>) public class ThreadPoolTest{ public static void main(String[] args)throws InterruptedException{ /** 创建线程池: 初始化线程数2 核心线程数4 最大线程数6 任务队列最多允许1000个任务 */ final ThreadPool threadPool = new BasicThreadPool(2,6,4,1000); //...