1. 程式人生 > >SpringData JPA 、Hibernate與Spring Boot整合

SpringData JPA 、Hibernate與Spring Boot整合

dependencies {
	compile('org.springframework.boot:spring-boot-starter-web')
	 //新增thymeleaf依賴
    compile('org.springframework.boot:spring-boot-starter-thymeleaf')
    //新增測試依賴
	testCompile('org.springframework.boot:spring-boot-starter-test')
	//新增Spring Data JAP的依賴
	compile('org.springframework.boot:spring-boot-starter-data-jpa')
	//新增Mysql連線驅動依賴
	runtime('mysql:mysql-connector-java')
	//新增H2的依賴
	runtime('com.h2database:h2:1.4.193')
}