The Proposed Final Draft (CR1) of Bean Validation 2.0 has been released earlier this week and it is time to release a version of the Reference Implementation compatible with it: here comes Hibernate Validator 6.0.0.CR1.

Note that Hibernate Validator 6 requires JDK 8 or above.

What’s new since Beta2

As the final release of Bean Validation is getting closer, we mainly focused on keeping up with the latest spec clarifications, fixing bugs and improving overall consistency.

We also added/improved a few things:

  • After a community survey, we decided to create specific annotations for @PositiveOrZero, @NegativeOrZero, @PastOrPresent and @FutureOrPresent instead of using annotation attributes.

  • CDI is now enabled for ValueExtractors loaded via the ServiceLoader. We also fixed a class loading issue in that area.

  • The programmatic API for @NotBlank, @NotEmpty and @Email is now using the new Bean Validation constraints instead of the Hibernate Validator specific ones.

  • We added automatic module names for the new Java 9 module system. You can find them in our reference documentation.

Finally, we made quite a lot of improvements to our testing infrastructure but you shouldn’t notice it (except if you come join us!).

The complete list of fixed issues can be found in the release notes.

Getting 6.0.0.CR1

To get the release with Maven, Gradle etc. use the GAV coordinates org.hibernate.validator:{hibernate-validator|hibernate-validator-cdi|hibernate-validator-annotation-processor}:6.0.0.CR1. Note that the group id has changed from org.hibernate (Hibernate Validator 5 and earlier) to org.hibernate.validator (from Hibernate Validator 6 onwards).

Alternatively, a distribution bundle containing all the bits is provided on SourceForge (TAR.GZ, ZIP).

Feedback, issues, ideas?

To get in touch, use the usual channels:

What’s next?

As we published the Proposed Final Draft, we are in the final stretch for Bean Validation 2.0, so if you spot any remaining issues or shortcomings in the spec draft, please let us know as soon as possible.

Testing the Reference Implementation is also a good way to help us finalize both the specification and the next major version of Hibernate Validator, now is the time!


Back to top