JPA Hibernate 框架就是一个 JPA 的实现。
Spring Data JAP 不是对 JPA 规范的具体实现,本身是一个抽象层。
- pom.xml 引入依赖
<!-- 基础父包 -->
<parent>
<groupId>org.springframework.boot</groupId>
<version>2.7.5</version>
<artifactId>spring-boot-starter-parent</artifactId>
</parent>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boo