The hibernate-types open-source project is born
Are you struggling with performance issues in your Spring, Jakarta EE, or Java EE application?
Imagine having a tool that could automatically detect performance issues in your JPA and Hibernate data access layer long before pushing a problematic change into production!
With the widespread adoption of AI agents generating code in a heartbeat, having such a tool that can watch your back and prevent performance issues during development, long before they affect production systems, can save your company a lot of money and make you a hero!
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 allowing performance issues to annoy your customers, you are better off preventing those issues using Hypersistence Optimizer and enjoying spending your time on the things that you love!
Introduction
Recently, I got a very interesting request from one of my readers. Since I’ve been providing many custom types to support JSON, ARRAY, or nullable Character types, I decided to start a new open-source project to make it easier for you to get these extra Hibernate Types.
Kudos to @vlad_mihalcea, the Hibernate Types library saved me tons of work yesterday by automagically mapping the PostgreSQL jsonb column to a POJO. Brilliant work 💪
— Tomasz Knyziak (@TomaszKnyziak) September 18, 2019
The project
As expected, the project is hosted on GitHub, so it’s business as usual.
To use it, you just have to set up a new Maven dependency in your project since all artifacts can be grabbed from Maven Central.
For Hibernate 6.0, use this dependency:
<dependency>
<groupId>com.vladmihalcea</groupId>
<artifactId>hibernate-types-60</artifactId>
<version>${hibernate-types.version}</version>
</dependency>
For Hibernate 5.5, use this dependency:
<dependency>
<groupId>com.vladmihalcea</groupId>
<artifactId>hibernate-types-55</artifactId>
<version>${hibernate-types.version}</version>
</dependency>
For Hibernate 5.4, 5.3, and 5.2, use this dependency:
<dependency>
<groupId>com.vladmihalcea</groupId>
<artifactId>hibernate-types-52</artifactId>
<version>${hibernate-types.version}</version>
</dependency>
For Hibernate 5.1 and 5.0, use this dependency:
<dependency>
<groupId>com.vladmihalcea</groupId>
<artifactId>hibernate-types-5</artifactId>
<version>${hibernate-types.version}</version>
</dependency>
For Hibernate 4.3, use this dependency:
<dependency>
<groupId>com.vladmihalcea</groupId>
<artifactId>hibernate-types-43</artifactId>
<version>${hibernate-types.version}</version>
</dependency>
For Hibernate 4.2 and 4.1, use this dependency:
<dependency>
<groupId>com.vladmihalcea</groupId>
<artifactId>hibernate-types-4</artifactId>
<version>${hibernate-types.version}</version>
</dependency>
For older versions of Hibernate, it’s time to upgrade and benefit from a great variety of features.
Extra Hibernate Types
The 1.0.0 version brings you the following Hibernate Types:
- Jackson
JsonNode - Any Java object to String or Binary JSON column mapping
- PostgreSQL ARRAY mapping
Characterto nullable CHAR columnImmutableTypeutility to simplifyUserTypeimplementations
If you enjoyed this article, I bet you are going to love my Book and Video Courses as well.
Conclusion
Stay tuned!
The next release is going to add support for combining the assigned identifier generator with either IDENTITY or SEQUENCE as well as the SEQUENCE locating mechanism explained in this article.
Therefore, it’s all about trade-offs, so choose wisely.





