High-Performance Hibernate Tutorial

I’ve been using Hibernate for almost a decade and I admit it was not an easy journey. This tutorial is actually a summary of my book, whose main goal is to provide guidelines and practical advice for optimizing the data access layer performance while maintaining a strong consistency transactional model.

This material is useful for both beginners and experienced developers, going beyond the reference documentation.

Tips and best practices




Connection management



Concurrency control




Stored procedures


If you like these articles, I bet you are going to love my book as well.


4 thoughts on “Hibernate

  1. Hi Vald,

    Thanks for providing these high quality tutorials around hibernate and JPA. They are very intuitive and useful. I went through most of the tutorials and couldn’t find anywhere you talked about mapping strategies(Per table, per class hierarchy etc…). Can I assume you are going to talk about those in a later tutorial or you always work with a 3rd normal form database schemas?


    1. When it comes to mappings, I always prefer simplicity. While you can model very exotic relations, those are very difficult to tune and they usually perform badly. For inheritance, I like to push the composition as much as possible. That’s why I don’t go for complex inheritance hierarchies, but rather have a common base entity which can easily swap in simpler many-to-one inheritance hierarchies. This resembles the JOINED inheritance, only it allows you to change from one type to the other without the base class primary key reusing hassle.

      1. Make sense.
        Most of the time, I go for the simple composition rather than inheritance.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s