On 6/1/11 6:05 PM, Mircea Markus wrote:
>>> Why are we actually using JGroups' state transfer with replication, but
>>> use our own state transfer with distribution ?
>>
>> I don't know, but guess it's because each node has a different set of
>> keys so no node has the same state as another ?
>
> You could still use JGroups state transfer; getState() would list the
> state provider as target node.
>
> In general, partial state transfer involves transferring (1) the partial
> state and (2) the digest, which is a vector of highest seqnos seen for
> every member. When we get a partial state, we always overwrite our own
> digest with the one received, and update our state accordingly. However,
> when this is done a couple of times, for different partial states, I'm
> not sure that we won't receive a few messages multiple times, due to the
> digest overwriting...
>
> I think the cleanest solution would be for you guys to reuse the state
> transfer you already use for state transfer in distribution mode.
+1. There's also transaction logic* related to state transfer, which would need to be
maintained in two implementations - not good!
* actually the transaction-failover logic needs to be revisited especially after the new
rebalancing code. Dan and I will go over it next week - we working at his place and this
will make things easier.
Excellent ! Let us know what the outcome is, naturally I'm especially
interested in the new rebalancing code since I wrote it ! :-)
Note that I'll be on vacation until June 11th.
Cheers,
--
Bela Ban
Lead JGroups / Clustering Team
JBoss