Linearizability is a lesser-known, yet omnipresent property of a data registry in the context of read and write operations that might happen concurrently.
This article aims to explain what linearizability consists of, and why it’s more prevalent that you might have previously thought.
Continue reading “A beginner’s guide to Linearizability”
While answering this StackOverflow question, I realized that it’s a good idea to summarize how various bidirectional associations should be synchronized when using JPA and Hibernate.
Therefore, in this article, you are going to learn how and also why you should always synchronize both sides of an entity relationship, no matter if it’s
Continue reading “How to synchronize bidirectional entity associations with JPA and Hibernate”
In a previous article, I explained how you could audit entity modifications using the JPA
@EntityListeners for embeddable types.
Since Hibernate ORM 5.2.17 now allows you to use the
@PreUpdate JPA entity listeners, we can simplify the previous example, as you will see in this article.
Continue reading “How to use @PrePersist and @PreUpdate on Embeddable with JPA and Hibernate”
I recently answered this question on the Hibernate forum, and since it’s a very good one, I decided to turn it into an article.
In this post, we will describe how the N+1 query issue is generated when using the second-level Hibernate Query Cache.
Continue reading “How to avoid the Hibernate Query Cache N+1 issue”
In this article, you are going to find out how to map an immutable entity when using JPA and Hibernate.
If your Domain Model requires that a given entity should not be modified by the data access logic, Hibernate can enforce this requirement if the entity is marked with the
Continue reading “How to map an immutable entity with JPA and Hibernate”