• Bug
  • Status: Closed
  • 2 Major
  • Resolution: Fixed
  • ehcache-core
  • alexsnaps
  • Reporter: cdennis
  • May 11, 2010
  • 0
  • Watchers: 0
  • July 27, 2012
  • May 20, 2010


When attempting to remove an expired element it is no longer always possible to acquire the necessary write lock, since the caller of the get may still be holding the read lock. This was observed in BlockingCache and fixed at the call site. It is still possible to create this situation however using the explicit locking module.


Fiona OShea 2010-05-18

Is this already fixed?

Chris Dennis 2010-05-18

I believe that Alex fixed this when he corrected my original fix for the BlockingCache bug. I’m assigning to him to confirm this and close the bug…

Alexander Snaps 2010-05-20

This is solved yes… Inline eviction will only try to acquire the write lock for an expired element. If it succeeds, the element will be evicted, otherwise it remains in the Store, yet the Cache.get() still returns null