sringboot的坑

最近新创建了一个springboot的空项目,运行时爆了一堆的错误

 原因是没有配置数据库,但我配置文件明明写了,那么只可能是springboot没有读到你的配置文件

 No active profile set, falling back to default profiles: default

先没有解决配置文件的问题,先将

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-jpa</artifactId>
</dependency>

注释后问题都解决了,那么为什么pringboot没有读到配置文件呢

原文地址:https://www.cnblogs.com/djh222/p/12176592.html