[infinispan-dev] Conditional cache operations useless with Optimistic locking?
Mircea Markus
mmarkus at redhat.com
Tue Mar 12 07:42:37 EDT 2013
On 8 Mar 2013, at 12:50, Sanne Grinovero wrote:
> I think using conditional operations is very useful even with
> optimistic locking: the single conditional operation might not make
> sense, but a transaction might include more operations and some of
> these operations might depend on the result of the conditional
> operation.
>
> I'd expect the conditional operation to only return the value based on
> current state (a prediction), and the transaction would fail if this
> value is no longer valid at commit time. So no locks need to be taken
> during the evaluation.
that's only if you have write skew check enabled.
Cheers,
--
Mircea Markus
Infinispan lead (www.infinispan.org)
More information about the infinispan-dev
mailing list