Spring Data JPA Interview Questions and Answers
1. What does JPA stand for? Java Persistence API 2. What's the difference between JPA and Spring Data JPA? JPA is a specification that standardizes the way Java Objects are mapped to a relational database system. Being just a specification, JPA consists of a set of interfaces, like EntityManagerFactory, EntityManager, and annotations that avail you to map a Java entity object to a database table. There are several JPA providers, like Hibernate, EclipseLink, or Open JPA which you can utilize. Spring Data JPA is not an implementation or JPA provider, it's just an abstraction used to significantly minimize the quantity of boilerplate code required to implement data access layers for various persistence stores. 3. What Is the Difference Between Hibernate and Spring Data JPA? Hibernate is a JPA implementation, while Spring Data JPA is a JPA Data Access Abstraction. Spring Data offers a solution to GenericDao custom implementations. It can withal engender JPA queries on your behalf t