Hbm Query support

It their any future plan to get rid of hbm query support ? as we are in face of hbm to annotation migration and we want to know should we work to migrate qbm query.

Are you referring to the hbm.xml format? If so, there is currently no defined plan but since version 6.0 it’s considered a deprecated format that it’s not receiving active support. There is still no 1-to-1 substitute for all legacy features, but we’re looking into how to ease migration and we might eventually decide do abandon the old format.

As a general rule, migrating to annotations (or even just the supported orm.xml format, through the hbm.xml transformer) is definetely a good idea and will enable you to use the latest features added to Hibernate ORM.

can you share doc which can use to understand latest feature of transform of hbm to orm.xml?

Here’s the javadoc of the transformer class: HbmXmlTransformer (Hibernate Javadocs).

At this time there is no official “guide” document, as I already said you can just try running the trasformer yourself through the TRANSFORM_HBM_XML mapping setting or even the task org.hibernate.orm.tooling.gradle.misc.TransformHbmXmlTask of Hibernate’s gradle plugin that does the same thing (see Gradle - Plugin: org.hibernate.orm).

is their any plan of deprecating orm , which one is the recommended approach for query.hbm : annotations or orm?

Unless you really want to keep your persistence information decoupled from your domain POJO mappings, I would personally recommend transitioning to annotations if possible: they are a lot more expressive, they’re closely tied to your entity mappings and it’s the preferred method used in most documentation and resources both from JPA and from Hibernate.

The orm.xml format is tightly related to annotations, once you have done the initial migration from hmb.xml it should be pretty easy to choose either one.