[
https://issues.jboss.org/browse/ISPN-1275?page=com.atlassian.jira.plugin....
]
Dan Berindei edited comment on ISPN-1275 at 7/29/11 6:38 AM:
-------------------------------------------------------------
Manik, it's a general consistent hash thing, if there is a collision (two nodes get
the same normalized hash) then the second node joining or leaving has a 50% chance of
changing the other node's hash id.
Obviously with virtual nodes the chance of a collision is much higher, and with 2000 nodes
in a 10240 hash space it's really close to 100%.
I think this also opens the possibility for ISPN-1170 to happen again:
{code}
hash(k) = 101
ch_0 = {A{r0,m0} = 100, B{r0,m0} = 102, C{r0,m1} = 103}
loc_0(k) = {B, C}
//after D{r1,m0} == 100 joins
ch_1 = {D{r1,m0} = 100, A{r0,m0} = 101, B{r0,m0} = 102, C{r0,m1} = 103}
loc_1(k) = {A, D}
{code}
was (Author: dan.berindei):
Manik, it's a general consistent hash thing, if there is a collision (two nodes
get the same normalized hash) then the second node joining or leaving has a 50% chance of
changing the other node's hash id.
Obviously with virtual nodes the chance of a collision is much higher, and with 2000 nodes
in a 10240 hash space it's really close to 100%.
I think this also opens the possibility for ISPN-1170 to happen again:
{code}
hash(k) = 101
ch_0 = {A{r0,m0} = 100, B{r0,m0} = 102, C{r0,m1} = 103}
loc_0(k) = {B, C}
//after D{r1,m0} == 100 joins
ch_0 = {D{r1,m0} = 100, A{r0,m0} = 101, B{r0,m0} = 102, C{r0,m1} = 103}
loc_1(k) = {A, D}
{code}
Virtual nodes producing same hash id for two different cluster nodes
--------------------------------------------------------------------
Key: ISPN-1275
URL:
https://issues.jboss.org/browse/ISPN-1275
Project: Infinispan
Issue Type: Bug
Components: Distributed Cache
Affects Versions: 5.0.0.CR8
Reporter: Galder ZamarreƱo
Assignee: Manik Surtani
Priority: Blocker
Fix For: 5.0.0.FINAL
Attachments: hashids.log
While working on ISPN-1273, I've discovered that when virtual nodes are enabled,
ConsistentHash.getHashIds(address) can return the same hash for two different cluster
nodes. Example: with 500 virtual nodes, both NodeA-23181 and NodeB-39177 produce hash id
*5289*. See attached log.
--
This message is automatically generated by JIRA.
For more information on JIRA, see:
http://www.atlassian.com/software/jira