taskkit 线程池数量由8增加到10

(cherry picked from commit 191ef1ff83)
master_haizei
grimm 2024-05-11 17:45:59 +08:00
parent c43b9eb56d
commit d09723580e
1 changed files with 2 additions and 2 deletions

View File

@ -190,8 +190,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) {