用CommonPool替代compleatable,避免大量异步同时执行

This commit is contained in:
wuweifeng10
2020-08-03 20:35:18 +08:00
parent 32a1a17526
commit 0eed91154d

View File

@@ -71,7 +71,7 @@ public class Async {
groupCallback = new DefaultGroupCallback();
}
IGroupCallback finalGroupCallback = groupCallback;
CompletableFuture.runAsync(() -> {
COMMON_POOL.submit(() -> {
try {
boolean success = beginWork(timeout, COMMON_POOL, workerWrapper);
if (success) {