测试线程池
parent
070b52c7a3
commit
38ea062c18
|
@ -221,7 +221,7 @@ public class PriorityThreadPool {
|
||||||
// 创建固定大小的线程池
|
// 创建固定大小的线程池
|
||||||
executor = new ThreadPoolExecutor(
|
executor = new ThreadPoolExecutor(
|
||||||
totalThreads, totalThreads,
|
totalThreads, totalThreads,
|
||||||
60L, TimeUnit.SECONDS,
|
30L, TimeUnit.SECONDS,
|
||||||
new LinkedBlockingQueue<Runnable>()
|
new LinkedBlockingQueue<Runnable>()
|
||||||
);
|
);
|
||||||
highPrioritySemaphore = new Semaphore(defaultHighThreads);
|
highPrioritySemaphore = new Semaphore(defaultHighThreads);
|
||||||
|
|
Loading…
Reference in New Issue