Hibernate Search does not reuse JavaReflectionManager from Hibernate.

Description

The code in the method SearchConfigurationFromHibernateCore#getReflectionManager() was written for the old Hibernate and does not work anymore with Hibernate 5. The ConfigurationService class from Hibernate does not have the method "getReflectionManager". And therefore the method SearchConfigurationFromHibernateCore#getReflectionManager() falls back to create its own instance of JavaReflectionManager. This leads to higher memory consumption.

I have prepared a pull request for this issue. But merging the pull request breaks the WildFly integration tests with following message:

To fix this error the definition of the Hibernate module in WildFly must be changed to export the "org.hibernate.commons-annotations" module (s. attached patch for details).

Environment

None

Assignee

Andrej Golovnin

Reporter

Andrej Golovnin

Labels

None

Suitable for new contributors

Yes, likely

Feedback Requested

None

Fix versions

Affects versions

Priority

Major
Configure