Joined: Mon Jun 15, 2009 12:47 pm Posts: 1
|
Hi,
I am getting org.hibernate.ObjectNotFoundException: No row with the given identifier exists when i enable second level cache on a entity which has one to one association with itself.
If i disable second level cache every thing works fine.
I am using hibernate with spring and added following to enable L2 cache in spring.xml file: <property name="hibernateProperties"> <props> <prop key="hibernate.show_sql">false</prop> <prop key="hibernate.dialect">org.hibernate.dialect.MySQLInnoDBDialect</prop> <prop key="hibernate.cache.use_query_cache">true</prop> <prop key="hibernate.cache.provider_class">org.hibernate.cache.EhCacheProvider</prop> <prop key="hibernate.cache.query_cache_factory">org.hibernate.cache.StandardQueryCacheFactory</prop> </props> </property>
I have also added <cache usage="read-write"> tag in the mapping file.
Any body having any idea about this problem? Thanks in advance
Manish
|
|