-
1. Re: can i have distributed caching with local locking ?
sudheerk84 Feb 20, 2012 10:51 AM (in response to sudheerk84)1 of 1 people found this helpfulcan i use this eagerLockSingleNode ?
i was checking teh documentation - http://docs.jboss.org/infinispan/5.0/apidocs/config.html
It has same description for eagerLockSingleNode and useEagerLocking .
For my use case, setting both flags true will server the purpose ?
Editing :
I found more info teh same here
thanks
-
2. Re: can i have distributed caching with local locking ?
galder.zamarreno Feb 21, 2012 10:41 AM (in response to sudheerk84)Hmmm, I don't see how these options are really gonna help. If you can assure that only one thread will modify a cache entry at one point, you could use SKIP_LOCKING flag, but there's danger in doing that.
You should also consider the unsafe options: https://docs.jboss.org/author/pages/viewpage.action?pageId=8093877
Finally, you should check the per-invocation flags that can help optimise your cache usage: https://docs.jboss.org/author/x/IgY5
-
3. Re: can i have distributed caching with local locking ?
sudheerk84 Feb 21, 2012 10:54 AM (in response to galder.zamarreno)I have multiple thread writing into teh cache locally , but no other node is writing into it.
When i use a cache.put() - I see that local lock is taken, and when i try to commit , it takes remote lock on all the other nodes. My problem here is , i do not want it to take remote locks on any other node(since non other node updates this cache).
So i assume by setting this eagerLockSingleNode, it will take only this local lock. meanwhile any other thread on this vm trying to update will wait. Isnt that right ?