mirror of
https://github.com/201206030/novel-plus.git
synced 2025-06-24 04:46:37 +00:00
v3.5.1发布
This commit is contained in:
@ -17,7 +17,7 @@ public class ThreadPoolConfig {
|
||||
@Bean
|
||||
public ThreadPoolExecutor threadPoolExecutor(ThreadPoolProperties properties){
|
||||
return new ThreadPoolExecutor(properties.getCorePoolSize(),properties.getMaximumPoolSize(),properties.getKeepAliveTime()
|
||||
, TimeUnit.MINUTES, new LinkedBlockingDeque<>(),new ThreadPoolExecutor.AbortPolicy());
|
||||
, TimeUnit.SECONDS, new LinkedBlockingDeque<>(properties.getQueueSize()),new ThreadPoolExecutor.AbortPolicy());
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -16,6 +16,7 @@ public class ThreadPoolProperties {
|
||||
private Integer corePoolSize;
|
||||
private Integer maximumPoolSize;
|
||||
private Long keepAliveTime;
|
||||
private Integer queueSize;
|
||||
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user