Spring Data JPA, Spring Data R2DBC & Hibernate Reactive

Kondah Mouad
Geek Culture
Published in
15 min readSep 11, 2022

--

Data Persistence allows applications to persist and retrieve information from non-volatile storage. In this environment, applications must either manage persistence themselves or use third-party solutions to handle database updates and retrievals.

In this article, we explore Spring Data JPA, Spring Data R2DBC and Hibernate Reactive projects. The idea is to compare what each project offers and lacks and to have a deep look at what happens under the hood.

Here is the content:

  • Java Persistence API (JPA)
  • JPA Metamodel
  • Hibernate
  • Spring Data JPA and R2DBC
  • Hibernate Reactive

1. Java Persistence API (JPA)

Java Persistence API (JPA) is a specification that standardises the way for managing persistence of Java Objects and their mapping to a relational database system. Internally, JPA uses the JDBC API to interact with the database.

Persistence APIs in Java are composed of the following components:

https://openjpa.apache.org/builds/1.0.2/apache-openjpa-1.0.2/docs/manual/jpa_overview_arch.html
  • Persistence provider: A persistence provider is a JPA implementation provided by a vendor. There are several JPA implementations out there like Hibernate, EclipseLink, or Open JPA.

--

--