Skip to content

Commit

Permalink
[ISSUE sofastack#1122] support custom asyncThreadPool
Browse files Browse the repository at this point in the history
  • Loading branch information
loongs-zhang committed Apr 16, 2022
1 parent 2f23db9 commit 5fcb099
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -100,4 +100,13 @@ public void rejectedExecution(Runnable r, ThreadPoolExecutor executor) {
}
return asyncThreadPool;
}

/**
* 设置callback用的线程池
*
* @param threadPoolExecutor callback用的线程池
*/
public static void setAsyncThreadPool(ThreadPoolExecutor threadPoolExecutor) {
AsyncRuntime.asyncThreadPool = threadPoolExecutor;
}
}

0 comments on commit 5fcb099

Please sign in to comment.