Conclusion
As we’ve seen now, there are several API’s and abstractions. Here’s a short list of what we covered:
JDBC API: The JDBC API is a low-level API to execute SQL queries on a database.
JDBC Driver: Each database vendor has to implement the JDBC API to allow connecting to their database. This library is called a JDBC driver.
Connection pool: On top of the JDBC API, there are also a few libraries that provide a generic JDBC DataSource that provides connection pooling. The default for Spring Boot is HikariCP.
Spring JDBC: Spring JDBC is a wrapper on top of the JDBC API to make it easier to write and execute queries.
JPA: JPA is a specification for Object-Relational Mapping in Java. It is part of Jakarta EE.
Hibernate: Hibernate is a library that implemented the JPA specification. It’s the default JPA implementation for Spring Boot.
Spring Data: Spring Data is an umbrella project that descibes how database interactions can happen through their repository API.
Spring Data JPA: This is an implementation of Spring Data on top of JPA.
Spring Data JDBC: This is an implementation of Spring Data on top of Spring JDBC. It comes with its own lightweight ORM framework.
Top comments (0)