@Configuration @EnableScheduling public class ScheduleConfig implements SchedulingConfigurer { @Override public void configureTasks(ScheduledTaskRegistrar taskRegistrar) { taskRegistrar.setScheduler(Executors.newScheduledThreadPool(5)); } }
标签:implements,定时器,Executors,配置,setScheduler,简单,taskRegistrar,public From: https://www.cnblogs.com/wojtek/p/17718412.html