Closed phejl closed 6 years ago
Thanks for opening this PR. Apologies for the delay in response as I was away on vacation.
A few things:
- Please add an example to the example project that will validate this change.
- Can you provide an example project that I can use to reproduce the original issue on my end?
I'll try. Just give me some time.
- Would you mind pointing me in the direction of the Hibernate plugin source code where they apply this logic? (I have been searching for it but have had difficulty locating it for some reason).
It is in grails.plugin.hibernate.HibernateGrailsPlugin.doWithSpring
line 73 of jar org.grails.plugins:hibernate5:6.0.10
in my case. From that point it is propagated (line 80) down to HibernateDatastoreSpringInitializer.getBeansDefinitions
where hibernateConnectionSourceFactory
bean is created with explicitly passed array of classes.
I have added test to the hibernate-filter-example
project.
In the attached zip file there is the simplest possible project to reproduce the issue. Just unpack it and run it - it will fail. Comment out the hibernate-filter-plugin
in build.gradle
and run it again - it will run just fine.
Fix for issue #8