15 Spring Data JPA outlined

Spring Data JPA outlined

Spring Spring is based on the Data JPA ORM frame basis, on a package JPA specification set JPA application framework, developers can use the minimalist and code to enable access to the database operations. It offers including CRUD etc., commonly used functions, and easy to expand! Learning and using Spring Data JPA can greatly improve development efficiency!


Spring Data JPA let us relief operations DAO layer, basically all CRUD can rely on it to achieve, in the actual work of the project, it is recommended to use Spring Data JPA + ORM (eg: hibernate) to complete the operation, so that different switching ORM provides great convenience for the frame, but also to the database layer operation more simple and convenient decoupling


SpringData Jpa greatly simplifies database access layer code. How to simplify it? Using Spring Data JPA, we just need to write the dao layer interface will automatically have the CRUD, pagination queries and other methods.

Relationship between Spring Data JPA with JPA and hibernate

JPA is a set of specifications, the interior is composed of abstract classes and interfaces.
Hibernate is a mature ORM framework and Hibernate implements JPA specification, so it can be referred to hibernate as an implementation of JPA, we are using the JPA API programming, means standing on a higher point of view of the problem (for interfaces programming)
Spring Spring provides the data JPA is a more advanced package of JPA operation, under JPA specification dedicated to data persistence solution.

 

Guess you like

Origin www.cnblogs.com/zhaochengf/p/12127649.html