2 Replies Latest reply on Jul 21, 2011 11:55 AM by dsb

    Understanding TopologyAwareConsistentHash

    dsb Newbie



      I am working through some prototype code to re-create the demo Bela presented at JBoss world on Geographic Failover (http://www.vimeo.com/24825312). I am running Infinispan 5.0.0.CR7 in a standalone mode (no JBoss). In the example below I am not using multiple sites via the JGroups RELAY protocol for simplicity but I am seeing the same behavior in that configuration as well.


      My question revolves around TopologyAwareConsistentHash and the concept of 'ownership'. In my setup I have a single cluster X that consists of nodes A, B & C. Each node is joining the cluster and creating a single cache entry. I am then tracking the location of those entries vs. where they were created and the number of entries in each cache. numOfOwners for TopologyAwareConsistentHash is 1.


      I am seeing cases where even though a cache entry is created on a specific node it may be owned elsewhere, my question is that if a given node A has created a single entry say E1 and that ownership is on node B, node A has a numberOfEntries count of 1. Does a cache entry have a local entry if the ownership is elsewhere in the cluster?