- Developing Middleware in Java EE 8
- Abdalla Mahmoud
- 243字
- 2021-07-23 19:24:35
Accessing the Database with JPA 2.1
The data access layer is the most fundamental part and the backbone of any enterprise application. The ultimate goal of any enterprise solution is to store and retrieve its data with respect to consistency, availability, and performance. A common problem arises when dealing with a relational database from an object-oriented system. All runtime data is represented as objects, where the real data is stored as rows in tables. When trying to save an object state into a row in a database table, or fetching some data from the database and wrapping the result back into an object again, a set of redundant programmatic statements should be written, which is very boring and actually old-school.
Object-to-relational mapping is a very common approach to overcoming this redundancy by providing a layer above the database access APIs, allowing developers to directly store and retrieve objects, and mapping their attributes directly to database tables and vice versa, providing a virtual object-oriented database interface for the actual relational data.
The Java Persistence API (JPA) does a great job at this by providing Java developers with all the required operations, mappings, and techniques for mapping objects into the relational database. In this chapter, we are going to learn how to use JPA for the following:
- Creating and using JPA entities
- Mapping entities to tables and columns
- Performing CRUD operations
- Mapping entity relationships
- Using the JPA query language and criteria APIs
- Mapping inheritance relationships
- Mastering OpenLayers 3
- Learn Blockchain Programming with JavaScript
- Spring 5.0 By Example
- 數據庫程序員面試筆試真題與解析
- Java 開發從入門到精通(第2版)
- Learning ArcGIS Pro 2
- PaaS程序設計
- Getting Started with PowerShell
- Android Application Development Cookbook(Second Edition)
- Python計算機視覺編程
- 微信小程序項目開發實戰
- ASP.NET Core and Angular 2
- Koa與Node.js開發實戰
- C語言程序設計實驗指導
- Perl 6 Deep Dive