High-Performance Java Persistence Newsletter, Issue 58

Are you struggling with performance issues in your Spring, Jakarta EE, or Java EE application?

What if there were a tool that could automatically detect what caused performance issues in your JPA and Hibernate data access layer?

Wouldn’t it be awesome to have such a tool to watch your application and prevent performance issues during development, long before they affect production systems?

Well, Hypersistence Optimizer is that tool! And it works with Spring Boot, Spring Framework, Jakarta EE, Java EE, Quarkus, Micronaut, or Play Framework.

So, rather than fixing performance issues in your production system on a Saturday night, you are better off using Hypersistence Optimizer to help you prevent those issues so that you can spend your time on the things that you love!

Introduction

Welcome to a new issue of the High-Performance Java Persistence Newsletter in which we share articles, videos, workshops, and StackOverflow answers that are very relevant to any developer who interacts with a database system using Java.

Articles

The pick of this edition is this series of articles about transaction isolation levels in PostgreSQL.

Speaking of database transactions, this article provides an in-depth analysis of the guarantees provided by the MySQL Repeatable Read default isolation level.

Hibernate 6.3 introduced support for the SQL UPSERT operation. While currently, this feature works with all the databases that support the MERGE statement, maybe in the future, it will also support Database-specific features, such as the ON DUPLICATE KEY UPDATE statement. For more details about this topic, check out this article.

If you’re using PostgreSQL, then you should definitely read the following two articles:

A very good article I read was this one about the typical threshold for determining if a given query is slow and needs optimization.

A lesser-used feature of Hibernate is that you can map multiple entities on the same database table, therefore allowing you to better control the number of columns that are fetched and updated. If you are interested in learning the best way you can use this feature, then check out this article.

Hibernate provides a bytecode enhancement mechanism that allows you to lazy load entity attributes or change the default dirty checking mechanism. While it’s common to enable this mechanism at built time, as explained in this article, this is now the only option. You can also enable bytecode instrumentation at runtime, as I explained in this article.

Project Releases

The 2.8 and 2.8.1 versions of Hypersistence Optimizer have been released. If you want to learn more about the optimization features brought by these new versions, then check out this page.

The 3.7 version of Hypersistence Utils has been released and allows you to use it with Hibernate 6.3.

The 42.7.1 version of the PostgreSQL JDBC Driver has been released and provides several bug fixes.

Spring Boot released the 3.2.1 version and brings you support for Hibernate 6.4.

Get in touch with my latest articles!

StackOverflow Answers

The following StackOverflow answers have been trending since the last newsletter episode:

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.