mirror of
https://gitee.com/jd-platform-opensource/asyncTool.git
synced 2024-12-31 15:35:34 +08:00
用CommonPool替代compleatable,避免大量异步同时执行
This commit is contained in:
parent
52ab114940
commit
6a77b0976d
@ -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…
Reference in New Issue
Block a user