taskkit 线程池数量由8增加到10
parent
0a61397686
commit
191ef1ff83
|
@ -188,8 +188,8 @@ public abstract class TaskKit {
|
|||
// 最佳的线程数 = CPU可用核心数 / (1 - 阻塞系数)
|
||||
// TODO 阻塞系数是不是需要有个setter方法能让使用者自由设置呢?
|
||||
num = (int)(cores / (1 - 0.9));
|
||||
if (num > 8) {
|
||||
num = 8;
|
||||
if (num > 10) {
|
||||
num = 10;
|
||||
}
|
||||
}
|
||||
catch (Throwable e) {
|
||||
|
|
Loading…
Reference in New Issue