Mastering Hibernate

Learn how to correctly utilize the most popular Object-Relational Mapping tool for your Enterprise application

Mastering Hibernate

Ramin Rad

Learn how to correctly utilize the most popular Object-Relational Mapping tool for your Enterprise application
Mapt Subscription
FREE
$29.99/m after trial
eBook
$16.80
RRP $23.99
Save 29%
Print + eBook
$29.99
RRP $29.99
What do I get with a Mapt Pro subscription?
  • Unlimited access to all Packt’s 5,000+ eBooks and Videos
  • Early Access content, Progress Tracking, and Assessments
  • 1 Free eBook or Video to download and keep every month after trial
What do I get with an eBook?
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with Print & eBook?
  • Get a paperback copy of the book delivered to you
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with a Video?
  • Download this Video course in MP4 format
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
$0.00
$16.80
$29.99
$29.99p/m after trial
RRP $23.99
RRP $29.99
Subscription
eBook
Print + eBook
Start 30 Day Trial
Subscribe and access every Packt eBook & Video.
 
  • 5,000+ eBooks & Videos
  • 50+ New titles a month
  • 1 Free eBook/Video to keep every month
Start Free Trial
 
Preview in Mapt

Book Details

ISBN 139781782175339
Paperback204 pages

Book Description

Hibernate has been so successful since its inception that it even influenced the Java Enterprise Edition specification in that the Java Persistence API was dramatically changed to do it the Hibernate way. Hibernate is the tool that solves the complex problem of Object Relational Mapping. It can be used in both Java Enterprise applications as well as .Net applications. Additionally, it can be used for both SQL and NoSQL data stores.

Some developers learn the basics of Hibernate and hit the ground quickly. But when demands go beyond the basics, they take a reactive approach instead of learning the fundamentals and core concepts. However, the secret to success for any good developer is knowing and understanding the tools at your disposal. It’s time to learn about your tool to use it better

This book first explores the internals of Hibernate by discussing what occurs inside a Hibernate session and how Entities are managed. Then, we cover core topics such as mapping, querying, caching, and we demonstrate how to use a wide range of very useful annotations.

Additionally, you will learn how to create event listeners or interceptors utilizing the improved architecture in the latest version of Hibernate.

Table of Contents

Chapter 1: Entity and Session
Why this book?
Quick Hibernate
Working with a session
Entity
Proxy objects
Batch processing
Summary
Chapter 2: Advanced Mapping
Mapping concepts
Association cardinality
Cascade operations
Inheritance
Enumeration and custom data type
Summary
Chapter 3: Working with Annotations
Mapping and association
Behavior
SQL/DDL modifier
Summary
Chapter 4: Advanced Fetching
Fetching strategy
Hibernate Query Language
Native SQL
Criteria objects
Filters
Pagination
Summary
Chapter 5: Hibernate Cache
Cache structure
Caching benefits and pitfalls
Caching strategies
Managing the cache
Cache metrics
Summary
Chapter 6: Events, Interceptors, and Envers
Services
Events
Interceptors
Envers
Summary
Chapter 7: Metrics and Statistics
Statistical data types
Statistics via JMX
Summary
Chapter 8: Addressing Architecture
Architecture matters
Transaction management
Concurrency
Scalability
Performance
Legacy application
The Cloud strategy
Summary
Chapter 9: EJB and Spring Context
Deployment
EJB
Spring
Summary

What You Will Learn

  • Understand the internals of a Hibernate session and how Entities are managed
  • Declare better mapping between entity classes and database tables
  • Manage entity associations and collections
  • Fetch data not just by entity ID, but also using HQL, Criteria Objects, Filters, and Native SQL
  • Observe the first and second level caches and find out how to manage them
  • Collect statistics and metrics data for further observation
  • Make your application work with multi-tenant databases

Authors

Table of Contents

Chapter 1: Entity and Session
Why this book?
Quick Hibernate
Working with a session
Entity
Proxy objects
Batch processing
Summary
Chapter 2: Advanced Mapping
Mapping concepts
Association cardinality
Cascade operations
Inheritance
Enumeration and custom data type
Summary
Chapter 3: Working with Annotations
Mapping and association
Behavior
SQL/DDL modifier
Summary
Chapter 4: Advanced Fetching
Fetching strategy
Hibernate Query Language
Native SQL
Criteria objects
Filters
Pagination
Summary
Chapter 5: Hibernate Cache
Cache structure
Caching benefits and pitfalls
Caching strategies
Managing the cache
Cache metrics
Summary
Chapter 6: Events, Interceptors, and Envers
Services
Events
Interceptors
Envers
Summary
Chapter 7: Metrics and Statistics
Statistical data types
Statistics via JMX
Summary
Chapter 8: Addressing Architecture
Architecture matters
Transaction management
Concurrency
Scalability
Performance
Legacy application
The Cloud strategy
Summary
Chapter 9: EJB and Spring Context
Deployment
EJB
Spring
Summary

Book Details

ISBN 139781782175339
Paperback204 pages
Read More

Read More Reviews

Recommended for You

Mastering Web Application Development with AngularJS Book Cover
Mastering Web Application Development with AngularJS
$ 26.99
$ 5.40
Java EE 7 Developer Handbook Book Cover
Java EE 7 Developer Handbook
$ 35.99
$ 25.20
Learning Docker Book Cover
Learning Docker
$ 39.99
$ 8.00
Git Version Control Cookbook Book Cover
Git Version Control Cookbook
$ 26.99
$ 18.90
RESTful Java Web Services - Second Edition Book Cover
RESTful Java Web Services - Second Edition
$ 35.99
$ 25.20
Test-Driven Java Development Book Cover
Test-Driven Java Development
$ 39.99
$ 28.00