1:官方doc: Interface used to indicate that a bean should run when it is contained within a SpringApplication. Multiple CommandLineRunner beans can be defined within the same application context and can be ordered using the Ordered interface or Order @Order annotation. 接口被用作将其加入spring容器中时执行其run方法。多个CommandLineRunner可以被同时执行在同一个spring上下文中并且执行顺序是以order注解的参数顺序一致。
If you need access to ApplicationArguments instead of the raw String array consider using ApplicationRunner. 如果你需要访问ApplicationArguments去替换掉字符串数组,可以考虑使用ApplicationRunner类。