Hi,
I want to open multiple session factories on a single machine. But I get the error of ehcache which says that it cannot open the second ehcache manager instance on the same local file path.
The exception is: org.hibernate.cache.CacheException: Attemp to restart an already started EhCahceProvider . Use sessionFactory.close() between repeated calls to buildSessionFactory. Consider using net.sf.ehcache.hibernate.SingletonEhCacheProvider. Error from ehcache was: cannot parseConfiguration CacheManager. Attempt to create a new instance of CacheManager using the diskStorePath ...... The source of the configuration was the classpath.
I guess this error has not been updated with the new versions of hibernate and ehcache because I couldnt find the class mentioned in the eexception.
* I am not configuring ehcache via ehcache.xml.
* I am using Hibernate 3.2 cr2 May 5, 2006
* Code is based on JPA.
* I do not explicitly define a cache provider in persistence.xml
* persistence.xml only defines the set of properties: dialect, driver, url, username, password, and hbm2ddl.auto.
I couldnt find any information on this issue. How can i configure hibernate or ehcache to be able to open multiple sesson factories.
Thanks in advance.
Siyamed
|