How do I make Grails 3.1.1 user Hibernate 5?
The following actions report Hibernate version 4.3.11.Final: In Grails 3.1.1
In build.gradle change the classpath dependency for the hibernate4 plugin at the top of the file in the buildscript{ dependencies {... section as follows:
classpath "org.grails.plugins:hibernate5:5.0.1"
The classpath section is there for the Gradle scrips like schemaExport, and that section does not support auto versioning.
Change the compile hibernate4 plugin dependency to the following:
compile "org.grails.plugins:hibernate5"
Add the following hibernate-core dependency:
compile "org.hibernate:hibernate-core:5.0.7.Final"
Change the hibernate-ehcache dependency to the 5.0.7.Final version.
compile "org.hibernate:hibernate-ehcache:5.0.7.Final"