SpringBoot 实现启动时执行指定任务任务
使用 ApplicationRunner 与使用 CommandLineRunner 类似,唯一的区别是 run 方法的参数上
CommandLineRunner run方法的参数是一个数组
ApplicationRunner run方法的参数是一个 ApplicationArguments 对象
使用 ApplicationRunner 与使用 CommandLineRunner 类似,唯一的区别是 run 方法的参数上
CommandLineRunner run方法的参数是一个数组
ApplicationRunner run方法的参数是一个 ApplicationArguments 对象