[infinispan-dev] Use of Inifnispan across data centers

Galder Zamarreño galder at redhat.com
Thu Aug 5 05:45:01 EDT 2010


On top of the issues you mentioned, you force all to have same communications layer, TCP or UDP.

Did you have a look at my Hot Rod presentation for JUDCon? http://www.jboss.org/events/JUDCon/presentations.html. You might check out the last bit of my presentation where I explained very briefly how Infinispan accross data centres could potentially be written with RemoteCacheStore hooking up different data centres via Hot Rod. Each dc could be configured with JGroups TCP/UDP while the inter dc traffic goes over Netty based TCP-NIO. An active/passive kind of layout would be relatively easy to achieve this way.

On Aug 5, 2010, at 9:29 AM, Bela Ban wrote:

> The other day I had an idea how we could use Infinispan across data centers:
> 
> Say we have 2 data centers: NYC and SFO. There are nodes A,B,C,D in NYC 
> and W,X,Y,Z in SFO.
> 
> We'd like to use Infinispan in DIST mode with numOwners == 2, and 
> ideally place 1 copy of a data in the NYC center and one in the SFO 
> center. (Of course, this would also work with numOwners > 2, we'd just 
> have to make sure the copies are distributed more or less evenly between 
> the 2 data centers).
> 
> To make this work, there are 2 things that need to be done:
> 
>   1. The nodes in NYC and SFO have to be in the same JGroups cluster.
>      This way Infinispan has insight into the membership and gets
>      notified of changes. The cluster would usually be TCP based, but
>      if there's multicasting available between the centers, then of
>      course multicasting could be used, too.
>   2. The nodes in NYC would have to have a logical name starting with
>      "nyc-", the ones in SFO "sfo-".
> 
> #2 is needed by Infinispan as input into its consistent hash function in 
> order to determine the nodes to store a given key/value. Say if we have 
> a view of
> {nyc-D, sfo-Y, sfo-W, nyc-B, nyc-C, sfo-Z, nyc-A, sfo-X}, then we could 
> come up with a consistent hash function which knows that there are 2 
> data centers and could place the nodes onto 2 different hash wheels and 
> pick one from each (if numOwners=2).
> 
> Yes, I know #1 sucks, but until we've implemented the more advanced 
> solutions (e.g. RELAY in JGroups, data center replication in 
> Infinispan), this seems to me a workable solution that could be 
> implemented in a short time.
> 
> WDYT ?
> 
> -- 
> Bela Ban
> Lead JGroups / Clustering Team
> JBoss
> 
> _______________________________________________
> infinispan-dev mailing list
> infinispan-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/infinispan-dev

--
Galder Zamarreño
Sr. Software Engineer
Infinispan, JBoss Cache




More information about the infinispan-dev mailing list