diff --git a/QuickStart.md b/QuickStart.md index ec1e1db5d60048d8b6d18625513065c2e916c24b..9f997ca56cae9ffe2fe19a67b1d2709bbed8f69a 100644 --- a/QuickStart.md +++ b/QuickStart.md @@ -493,7 +493,7 @@ Async.work(1000, Executors.newFixedThreadPool(2),a).awaitFinish(); WorkerWrapper会在这些情况被运行: -* 在`Async.beginWork`中传入wrapper +* 在`Async.work`中传入wrapper * 上游wrapper完成后被调用 开始运行时,执行逻辑如下图所示: @@ -1259,11 +1259,11 @@ class Case7 { ### 设置超时 -可以在`Async.beginWork(/* ... */)`中传入总超时时间,也可以对单个wrapper设置超时时间。 +可以在`Async.work(/* ... */)`中传入总超时时间,也可以对单个wrapper设置超时时间。 #### 总任务时间超时 -在`Async.beginWork`方法中可以指定总超时时间。 +在`Async.work`方法中可以指定总超时时间。 #### 单wrapper任务时间超时 diff --git a/asyncTool-core/src/main/java/com/jd/platform/async/executor/Async.java b/asyncTool-core/src/main/java/com/jd/platform/async/executor/Async.java index 8948d8d11792b4b27cff13030dbdc1670209b275..e7649cb32c4deafec675cfa4e161156e19de0c09 100644 --- a/asyncTool-core/src/main/java/com/jd/platform/async/executor/Async.java +++ b/asyncTool-core/src/main/java/com/jd/platform/async/executor/Async.java @@ -126,6 +126,7 @@ public class Async { /** * 该方法将会返回{@link #COMMON_POOL},如果还未初始化则会懒加载初始化后再返回。 + * 详情参考{@link #COMMON_POOL}上的注解 */ public static ThreadPoolExecutor getCommonPool() { if (COMMON_POOL == null) {