[infinispan-dev] Can we replace Hypersonic with...
Manik Surtani
manik at jboss.org
Fri Jan 7 06:50:08 EST 2011
On 7 Jan 2011, at 11:44, Mark Little wrote:
>
> On 5 Jan 2011, at 10:53, Mircea Markus wrote:
>
>>
>> On 16 Dec 2010, at 10:51, Manik Surtani wrote:
>>
>>> Ah right, I get your point. So there are 2 cases:
>>>
>>> 1) When the failing resource manager is *not* an Infinispan node: returning a list of prepared or heuristically committed Xids is trivial for Infinispan since (a) we maintain an internal list of prepared txs, and (b) we don't heuristically commit. (Mircea can confirm this)
>> re: (b) - we do heuristically rollback: if a node where a tx originated crashes the changes/locks held on behalf of that transaction on other nodes are rollback heuristically. Right now we don't announce the TM about this heuristic decision. One way of handling this might be by remembering the transaction on one of the nodes where we roll it back and then inform the TM about it through XAResource.recover
>
> Bad, bad, bad, bad, bad. Oh, and it's bad. :-)
>
>>>
>>> 2) When the failing resource manager is an Infinispan node (failed and restarted, for example), and the TM calls recover on this node. In this case, recover will return a null, which, correctly, will lead the TM to believe that there are no prepared or heuristically committed txs on this node - which is correct, since the node would have been reset to the last-known stable state prior to the failure.
>> Not sure this is entirely correct, as we do make an heuristic decision to rollback the tx started on the failing node.
>
> Yes, that's bad too ;-)
Yup - this is what we're realising in the parallel discussion with Jonathan.
--
Manik Surtani
manik at jboss.org
twitter.com/maniksurtani
Lead, Infinispan
http://www.infinispan.org
More information about the infinispan-dev
mailing list