Tags
Authors
Welcome to the Hibernate community newsletter in which we share blog posts, forum, and StackOverflow questions that are especially relevant to our users.
This is a first Beta release in the Hibernate ORM 5.3 family. 5.3 represents a JPA 2.2 compatible version on top of 5.2 which includes the changes discussed below.
See Jira for the complete list of changes
See the downloads page for details on obtaining this release
NOTE : we have been having trouble getting documentation uploaded to the JBoss doc server. So the documentation may not be available online at this time. In that case, the documentation can be obtained from the release bundles from SourceForge. See the downloads page
We decided to do another release of the 5.1 series to fix some bugs to be included in an upcoming version of WildFly. This may be the last release of the 5.1 series, so we recommend that you migrate to 5.2 for future bugfixes.
Hibernate ORM 5.1.11.Final:
-
tag is here;
-
changes are listed here (or, for people without a Hibernate Jira account, here);
-
release bundles are at SourceForge and BinTray.
Welcome to the Hibernate community newsletter in which we share blog posts, forum, and StackOverflow questions that are especially relevant to our users.
We used to be very conservative on the constraints included in Hibernate Validator but we changed this policy recently and we would like to have more constraints built-in.
Of course, we won’t accept everything: the proposed constraints needs to be of general usage and well defined but the idea is to have more features in Hibernate Validator out of the box.
This post will be useful to those who have some interesting custom Bean Validation constraints and want to share them with the community.
[ ... ]
We just released the 6.0.7.Final version of Hibernate Validator containing a couple of enhancements.
This is a recommended upgrade for everyone using Hibernate Validator 6.0.x and it is a drop-in replacement of 6.0.5.Final.
One of the most exciting features in Java 9 are modular runtime images. Using the new jlink utility, you can create customized distributions which contain your app, its dependencies and just the JDK modules which it needs. For instance, a simple service based on the Undertow web server can be packaged into an image of just 25 MB, batteries included.
While that’s pretty cool already, it gets even nicer, as jlink provides a plug-in mechanism which allows to fine-tune the contents modular runtime images as they are created. There’s a set of jlink plug-ins coming with the JDK, e.g. for compressing image contents or removing debug symbols. But many more use cases may benefit from this API, for instance one could imagine plug-ins for removing un-used code or for performing byte code instrumentation of JPA entities. In the following, we’ll create a plug-in for adding an annotation index to the created image. At runtime, this index can then be used to discover annotations very efficiently, i.e. without loading classes and using reflection.
Sound great?
For sure it does, there’s just one catch: the jlink plug-in API is not a supported part of the JDK as of Java 9.
In fact, its packages are not even exported from the jdk.jlink
module.
This means some tricks are required to create custom plug-ins and run the jlink tool with these plug-ins enabled.
The API may change in future Java versions, so any custom plug-in may break.
Nevertheless it’s definitely worth to explore the API and see what it can do. It’s my hope that it’ll be promoted to a public API eventually.
Welcome to the Hibernate community newsletter in which we share blog posts, forum, and StackOverflow questions that are especially relevant to our users.
Without doubt, the module system (JPMS) is the most prominent feature of Java 9. But there are many other useful additions to the JDK, which have not been discussed as widely yet.
One of them is the new ToolProvider
SPI, which defines a uniform way to invoke all the tools coming with the JDK (e.g. jar
, jlink
etc.) in a programmatic way.
E.g. imagine you’d like to create a JAR archive from within your Java application.
Before Java 9, you had two options to do so:
-
Start a separate process to run the
jar
binary -
Find out which classes are used by the
jar
command internally and invoke them directly
Neither option is ideal.
The former incurs some overhead for forking an OS level process and it requires a bit of coding to locate the binary to execute in the Java home directory and to correctly capture any output of the forked process.
The second option doesn’t come with the disadvantages of forking a new process, but it requires knowledge about the implementation of the tool to execute.
So for instance in the case of the jar
command, you’d have to know that java.util.jar.JarOutputStream
is used to produce JAR files.
Originally started as a Google Summer of Code project by Mincong Huang, Hibernate Search 5.9 will feature integration with JSR 352, "Batch Applications for the Java Platform". This integration provides a new implementation of mass indexing (indexing a high volume of entities) as a JSR 352 job.
Yesterday we released 5.9.0.Beta1 so you can try it out already!
Why is it nice? How to use it? Let’s find out!