Open dabeeeenster opened 7 years ago
You have to use newer package for sessionFactory as described here http://www.ehcache.org/documentation/2.7/integrations/hibernate.html
I got something working with putting
hibernate.cache.region.factory_class=org.hibernate.cache.ehcache.SingletonEhCacheRegionFactory
But I am not sure that using Singelton factory class is actually the best idea
Also got it working with hibernate.cache.region.factory_class=org.hibernate.cache.ehcache.EhCacheRegionFactory
For this I added custom cache configuration file and hibernate.properties file to app directory. In hibernate.properties files I specified the custom cache configuration location
net.sf.ehcache.configurationResourceName=../conf/myehcache.xml
Referencing #952 I've tried to get this working in 1.4.4 but am getting errors. If I add this to my
application.conf
I get the following error:
I noticed that the package name for
EhCacheRegionFactory
in the newly included jar wasorg.hibernate.cache.ehcache.EhCacheRegionFactory
but setting that in the application.conf also errors. Is anyone else able to get this working?