Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

异步执行 #65

Open
FS1360472174 opened this issue Feb 11, 2018 · 0 comments
Open

异步执行 #65

FS1360472174 opened this issue Feb 11, 2018 · 0 comments

Comments

@FS1360472174
Copy link
Owner

定义一个线程池,然后在代码中使用@async
<task:executor id="asyncTaskExecutor" pool-size="10"/>
<task:scheduler id="runnablesScheduler" pool-size="3"/>
<task:annotation-driven executor="asyncTaskExecutor" scheduler="runnablesScheduler"/>

可以为不同的异步任务定义不同的线程池去执行
http://blog.csdn.net/clementad/article/details/47403185

对于springboot的话,可以使用一个java config配置一下线程池

http://blog.csdn.net/clementad/article/details/53607311

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant