-
1. Re: PojoCache 2.0: New tree structure, optimistic locking &
ben.wang Dec 21, 2006 5:53 AM (in response to chasta)Hmmn... You are right this is problematic. Each time when a pojo is attached, a new cache node will be created under __JBossInternal__. So for optimistic locking this will be problem for concurrent transaction. This will evitably create high rate of rollback and degrade the performance.
I ahve created a jira:
http://jira.jboss.com/jira/browse/JBCACHE-915
A partial workaround is to use "region" in cache such that __JBossInternal__ is separate for each region. However, for concurrent access under the same region, the problem would still exist.
Any reason that you must use optimistic locking? -
2. Re: PojoCache 2.0: New tree structure, optimistic locking &
manik Dec 21, 2006 8:46 PM (in response to chasta)Does this also affect the 1.4.x series? Specifically 1.4.1.CR1 (released earlier today) with a lot of improvements around optimistic locking concurrency? (These improvements will make it into the next 2.0.0.ALPHA2 as well)
-
3. Re: PojoCache 2.0: New tree structure, optimistic locking &
ben.wang Dec 22, 2006 3:46 AM (in response to chasta)It is not that servere in 1.4 because __JBossInternal__ is used only for shared references. So if there is creation of shared reference POJO under concurrent tx, then it will rollback. Otherwise, thing as usual.
-
4. Re: PojoCache 2.0: New tree structure, optimistic locking &
chasta Dec 22, 2006 11:53 AM (in response to chasta)Thanks for your reply.
Unfortunately, I need to use optimistic locking because in my usage scenario, deadlock prevention and/or recovery will be very hard when using pessimistic locking... That was one of the reasons for us to use JBossCache in the first place...
Any chance this will get fixed in ALPHA2 ?