- Caused by: javax.persistence.PersistenceException:
Attempt to restart an already started EhCacheProvider.
Use sessionFactory.close() between repeated calls to
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 "/tmp" which
is already used by an existing CacheManager.
Setting the hibernate property:
Setting the property to net.sf.ehcache.hibernate.SingletonEhCacheProvider may work as well,
but I haven't test yet.
- org.hibernate.AnnotationException: Use of @OneToMany or @ManyToMany targeting an unmapped class:...
I had a property annotated with @OneToMany targeting an @Embedabble @MappedSuperclass.
I found the solution in the Hibernate Forum:
You should use @CollectionOfElements instead of @*ToMany, if your association is not pointing to an entity.
Tuesday, June 13, 2006
Updating to Hibernate Core 3.2.0.cr2
After updating from Hibernate Core 3.1.2 and Hibernate Annotation 3.1beta8 to Hibernate Core 3.2.0.cr2 and Hibernate Annotations 3.2.0.cr1 I was facing two problems: