线程池初始化参数

线程池初始化参数

学习了:https://www.jianshu.com/p/210eab345423

int corePoolSize => 该线程池中核心线程数最大值
int maximumPoolSize 该线程池中线程总数最大值
long keepAliveTime 该线程池中非核心线程闲置超时时长
TimeUnit unit keepAliveTime的单位
BlockingQueue<Runnable> workQueue 该线程池中的任务队列:维护着等待执行的Runnable对象
ThreadFactory threadFactory 创建线程的方式,这是一个接口,你new他的时候需要实现他的Thread newThread(Runnable r)方法,
RejectedExecutionHandler handler 抛出异常专用的
原文地址:https://www.cnblogs.com/stono/p/8168950.html