Hibernate Validator 9.0.0.Beta3 is out

Posted by    |      

We just published Hibernate Validator 9.0.0.Beta3, the next beta release of the new 9.0 series of Hibernate Validator.

This series targets Jakarta EE 11. It is the implementation of the Jakarta Validation 3.1. Compared to the previous release in this series, this version removes a few more constraints, configuration properties and APIs, which have been deprecated for several major versions. We have also identified some possible areas to improve while testing the previous version in the downstream projects. Also, there are some bug fixes.

What’s new

For a summary of all new features and improvements since 8.0, head to the dedicated page on hibernate.org.

Jakarta EE 11 and Jakarta Validation 3.1

As a reminder: the 9.0 series targets Jakarta EE 11 and implements Jakarta Validation 3.1. The 3.1 update of the specification does not bring many changes:

  • The minimum required Java version is set to 17.

  • The specification was renamed from Jakarta Bean Validation to Jakarta Validation.

  • Validation of Java record types was clarified (this has been supported by Hibernate Validator for some time).

Removal of the deprecated APIs

There were a few constraints, configuration properties, and public API methods/classes that have been deprecated for several major versions now, with available alternatives to migrate to. With this new major version of Hibernate Validator some of these are removed. For a detailed list of removed deprecated items see the migration guide.

OSGi integration clarification

Starting with Hibernate Validator 9.0, the Hibernate team no longer tests nor maintains the OSGi integration. For users who would want to experiment with Hibernate Validator in an OSGi environment, we will keep the existing manifest entries in place as they were.

Even though we no longer maintain the Hibernate Validator OSGi integration, we do encourage the community members interested in it to come forward with pull requests if they encounter some issues. In such a case, we will try to guide the submitter through the contribution process and assess the suggested patch for inclusion in the build.

Other improvements and bug fixes

  • HV-2031: Make PredefinedScopeHibernateValidatorFactory aware of types for which constraint mappings are defined only in XML

  • HV-2029: Fix an issue when an exactly the same ConvertGroup is defined on both original and overridden methods in a class hierarchy leads to a constraint declaration exception.

  • HV-2018: Fix an issue related to validating values via Validator#validateValue(..), when the supplied bean type is an interface.

And more. Please see the release notes for a complete list of changes since the previous releases.

How to get this release

Hibernate Validator 9 targets the upcoming Jakarta EE 11.

All details are available and up to date on the dedicated page on hibernate.org.

Getting started, migrating

For new applications, please refer to the getting started guide:

For existing applications, Hibernate Validator 9.0 is most cases a drop-in replacement for 8.0, assuming you also upgrade the other Jakarta EE 11 related dependencies and were not relying on the removed deprecated APIs. Information about deprecated configuration and API is included in the migration guide.

Feedback, issues, ideas?

To get in touch, use the usual channels:


Back to top