With other Java EE 8 tech previews we handle it by loading the correct resource based on a system property. Is this not possible with Hibernate for some reason? For example have a look at the javax.validation.api module [1].

[1]: https://github.com/wildfly/wildfly/blob/master/servlet-feature-pack/src/main/resources/modules/system/layers/base/javax/validation/api/main/module.xml#L26-L42

On Wed, Feb 21, 2018 at 1:20 PM, Scott Marlow <smarlow@redhat.com> wrote:

On Wed, Feb 21, 2018 at 3:36 PM, James Perkins <jperkins@redhat.com> wrote:
Is there a need to create a new module?

Yes, WildFly needs to keep including the current Hibernate ORM  5.1 jar for application compatibility but we also need to include the newer Hibernate ORM 5.3+ jar for EE 8/JPA 2.2 use.  So, we really need a new ORM module, since we will keep both Hibernate versions in WildFly for a while (ORM 5.3 may get swapped out with a newer version later, TBD).

Scott




--
James R. Perkins
JBoss by Red Hat