mirror of
https://gitee.com/jd-platform-opensource/asyncTool.git
synced 2025-12-26 05:37:19 +08:00
用CommonPool替代compleatable,避免大量异步同时执行
This commit is contained in:
parent
32a1a17526
commit
0eed91154d
@ -71,7 +71,7 @@ public class Async {
|
|||||||
groupCallback = new DefaultGroupCallback();
|
groupCallback = new DefaultGroupCallback();
|
||||||
}
|
}
|
||||||
IGroupCallback finalGroupCallback = groupCallback;
|
IGroupCallback finalGroupCallback = groupCallback;
|
||||||
CompletableFuture.runAsync(() -> {
|
COMMON_POOL.submit(() -> {
|
||||||
try {
|
try {
|
||||||
boolean success = beginWork(timeout, COMMON_POOL, workerWrapper);
|
boolean success = beginWork(timeout, COMMON_POOL, workerWrapper);
|
||||||
if (success) {
|
if (success) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user