I\'m using spring-boot
and @Scheduled
annotation to execute some tasks.
How can I find out what the default pool size of scheduled tasks is
The default scheduler pool size in spring-boot is only one.
In org.springframework.scheduling.config.ScheduledTaskRegistrar
:
/**
* Schedule all registered tasks against the underlying
* {@linkplain #setTaskScheduler(TaskScheduler) task scheduler}.
*/
@SuppressWarnings("deprecation")
protected void scheduleTasks() {
if (this.taskScheduler == null) {
this.localExecutor = Executors.newSingleThreadScheduledExecutor();
this.taskScheduler = new ConcurrentTaskScheduler(this.localExecutor);
}
...
}