]
Gail Badner resolved HHH-6296.
------------------------------
Resolution: Duplicate
Assignee: Gail Badner
Unnecessary lock in UpdateTimestampsCache
-----------------------------------------
Key: HHH-6296
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-6296
Project: Hibernate Core
Issue Type: Patch
Components: caching (L2)
Affects Versions: 3.6.1, 3.6.2, 3.6.3, 3.6.4
Environment: Hibernate 3.6.4
Reporter: Alexandre Thiel
Assignee: Gail Badner
Priority: Minor
Attachments: UpdateTimestampsCache.java.diff
Non transactional queries call UpdateTimestmapsCache.invalidate method with an empty
array parameter but still acquire a WriteLock which cause a performance bottle neck under
heavy load.
GNU-Diff Patch for org.hibernate.cache.UpdateTimestampsCache attached
Thread dump example :
"TP-Processor10" daemon prio=10 tid=0x00000000415cb800 nid=0x6803 waiting on
condition [0x00007f1346594000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x00007f1370f6d1c0> (a
java.util.concurrent.locks.ReentrantReadWriteLock$NonfairSync)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:158)
at
java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:747)
at
java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireQueued(AbstractQueuedSynchronizer.java:778)
at
java.util.concurrent.locks.AbstractQueuedSynchronizer.acquire(AbstractQueuedSynchronizer.java:1114)
at
java.util.concurrent.locks.ReentrantReadWriteLock$WriteLock.lock(ReentrantReadWriteLock.java:807)
at org.hibernate.cache.UpdateTimestampsCache.invalidate(UpdateTimestampsCache.java:88)
at
org.hibernate.engine.ActionQueue$AfterTransactionCompletionProcessQueue.afterTransactionCompletion(ActionQueue.java:604)
at org.hibernate.engine.ActionQueue.afterTransactionCompletion(ActionQueue.java:209)
at org.hibernate.impl.SessionImpl.afterTransactionCompletion(SessionImpl.java:602)
at org.hibernate.jdbc.JDBCContext.afterNontransactionalQuery(JDBCContext.java:292)
at org.hibernate.impl.SessionImpl.afterOperation(SessionImpl.java:595)
at org.hibernate.impl.SessionImpl.load(SessionImpl.java:993)
at org.hibernate.impl.SessionImpl.load(SessionImpl.java:978)
--
This message is automatically generated by JIRA.
For more information on JIRA, see: