[infinispan-dev] Using infinispan as quorum-based nosql

Mircea Markus mmarkus at redhat.com
Thu Jun 6 13:14:12 EDT 2013


On 6 Jun 2013, at 10:09, Dan Berindei <dan.berindei at gmail.com> wrote:

> Say you have two transactions, tx1 and tx2. They both send a LockControlCommand(k1) to the primary owner of k1 (let's call it B).
> If the lock commands use SYNCHRONOUS_IGNORE_LEAVERS and B dies while processing the commands, both tx1 and tx2 will think they have succeeded in locking k1.
> 
> So you're right, everything should be locked before prepare in pessimistic mode, but LockControlCommands are also susceptible to SuspectExceptions. On the other hand, you can use SYNCHRONOUS mode for LockControlCommands and you can just retry the transaction in case of a SuspectException. 
> 
> Unfortunately, you can't retry the transaction if the PrepareCommand fails (in pessimistic mode; or the CommitCommand in optimistic mode), because it is executed in the commit phase. The transaction manager swallows all the exceptions in the commit phase, making it impossible to see if it failed because of a node leaving. I guess this means I should increase the priority of https://issues.jboss.org/browse/ISPN-2402 ...
+1 for increasing the priority. A bit too late for 5.3.0 stream though, as this is a rather large change.
Cheers,
-- 
Mircea Markus
Infinispan lead (www.infinispan.org)







More information about the infinispan-dev mailing list