[hibernate-issues] [Hibernate-JIRA] Created: (HHH-5394) Lock is not released after updating Entity, "Cached item was locked" is seen in the logs
Samuel Mendenhall (JIRA)
noreply at atlassian.com
Mon Jul 19 10:15:35 EDT 2010
Lock is not released after updating Entity, "Cached item was locked" is seen in the logs
----------------------------------------------------------------------------------------
Key: HHH-5394
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5394
Project: Hibernate Core
Issue Type: Bug
Components: caching (L2)
Affects Versions: 3.3.1
Environment: Hibernate 3.3
Reporter: Samuel Mendenhall
Attachments: test.zip
See attached project to reproduce. In short, create an object, update it, and perform a second get on that object (caching is on yes), in that second get in the hibernate trace logging "cached item was locked" is seen. The operations are done serially and not in parallel, so the cache item should not still be locked as in http://fisheye.jboss.org/browse/Hibernate/core/trunk/core/src/main/java/org/hibernate/cache/ReadWriteCache.java?r=HEAD there is a
finally {
cache.unlock(key);
}
Example of the logs:
06-22 13:36:17,416 TRACE [org.hibernate.event.def.DefaultLoadEventListener] loading entity: [org.domain.seam202fp.entity.Parent#1]
2010-06-22 13:36:17,416 TRACE [org.hibernate.event.def.DefaultLoadEventListener] attempting to resolve: [org.domain.seam202fp.entity.Parent#1]
2010-06-22 13:36:17,416 TRACE [org.hibernate.cache.ReadWriteCache] Cache lookup: org.domain.seam202fp.entity.Parent#1
2010-06-22 13:36:17,416 TRACE [org.hibernate.cache.ReadWriteCache] Cached item was locked: org.domain.seam202fp.entity.Parent#1
2010-06-22 13:36:17,416 TRACE [org.hibernate.event.def.DefaultLoadEventListener] object not resolved in any cache: [org.domain.seam202fp.entity.Parent#1]
2010-06-22 13:36:17,416 TRACE [org.hibernate.persister.entity.AbstractEntityPersister] Fetching entity: [org.domain.seam202fp.entity.Parent#1]
2010-06-22 13:36:17,416 DEBUG [org.hibernate.loader.Loader] loading entity: [org.domain.seam202fp.entity.Parent#1]
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list