infinispan/infinispan — pull request #568 by danberindei (2011-10-12 08:12:21+00:00)
Title: ISPN-658 - Asymmetric clusters should be supported

https://issues.jboss.org/browse/ISPN-658

Here's the asymmetric cache support guys, it's a lot of code...
It mostly folows the design at http://community.jboss.org/wiki/AsymmetricCachesAndManualRehashingDesign.

I'm aware of a few things that need changing:
* CacheViewsManagerImpl is kind of big, and especially recoverViews().
* There is no functional test for asymmetric cache support, and CacheViewManagerImpl could have a unit test.
* I have a new executor that's not configurable. I've talked a bit with Galder about this, but I'm not sure if I should expose it or reuse another executor like the async transport executor and rename the thread.
* For now the only view installation policy is to not allow two views to be installed at the same time. There is a separate JIRA for manual rehashing though, ISPN-1394, so I'll move the policy there.
* We have a few tests failing from time to time because of RehashInProgressExceptions (deadlock between ongoing transactions and the state transfer process). I think we can implement a retry mechanism, but I need to think about it some more.