|
@@ -7,7 +7,7 @@ import java.util.function.Supplier;
|
|
|
|
|
|
@Slf4j
|
|
|
public class RunnableUtils {
|
|
|
- private static final int IN_USE_SIZE = 40;
|
|
|
+ private static final int IN_USE_SIZE = 100;
|
|
|
private static final ExecutorService service = createPoolExecutor();
|
|
|
|
|
|
public static void start(Running run) {
|
|
@@ -37,7 +37,7 @@ public class RunnableUtils {
|
|
|
}
|
|
|
|
|
|
private static ExecutorService createPoolExecutor() {
|
|
|
- return new ThreadPoolExecutor(IN_USE_SIZE, IN_USE_SIZE, 60L, TimeUnit.SECONDS, new SynchronousQueue());
|
|
|
+ return new ThreadPoolExecutor(IN_USE_SIZE, IN_USE_SIZE, 60L, TimeUnit.SECONDS, new SynchronousQueue(), new ThreadPoolExecutor.CallerRunsPolicy());
|
|
|
}
|
|
|
|
|
|
}
|