原因1: pom.xml 配置缺少version
报错:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-cache</artifactId>
</dependency>
改正:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-cache</artifactId>
<version>2.1.6.RELEASE</version>
</dependency>
其他情况可参考:
SpringBoot 2.0 报错: Failed to configure a DataSource: 'url' attribute is not specified and no embe... https://www.jianshu.com/p/836d455663da
共同学习,共同进步,若有补充,欢迎指出,谢谢!