Question: how jpa works in spring?
Answer: Spring Data JPA is a part of the Spring Data family. ... The Spring Data JPA framework can then inspect that contract, and automatically build the interface implementation under the covers for you. For Spring Data JPA to intelligently generate an implementation of your Repository interface, a Query DSL is needed.