Spring-boot 启动错误

     Spring-boot 启动时发生警告

     Your ApplicationContext is unlikely to start due to a @ComponentScan of the default package. 如下图所示。


    解决:把注解@SpringBootApplication的类  放到包里面就可以了,不能裸建个类。



下图为spring官方文档中的记录

下面为翻译


 
 
 
 

猜你喜欢

转载自blog.csdn.net/qq_29622845/article/details/80929373