hi do you have any formula for allocating nodes equally 

On Tuesday, September 3, 2013 6:53:55 PM UTC+5:30, m2guru wrote:
>
> Try it as the integer modulo 1000 
>
> (<bigint> % 1000) -1 = ringnum
>
> On Sep 3, 2013, at 2:25 AM, indrajith m <indrajit...@gmail.com<javascript:>> 
> wrote:
>
> *Hi,*
>
> *I am working on consistent hashing am getting the problem while 
> generating the consistent Id in consistent circle am following these method
> *
>
> *My consistent circle lower limit is->0 and upper limit is 999*
>
> *So my consistent node id should be in between 0 and 999 *
>
> *Here I am taking the Node IP and port number (192.168.9.23:11211)*
>
> *Then Converting IP details to Hash code based on the hashing algorithm 
> so am getting one integer like (8695869568) ten digit number *
>
> *From that hash code am taking the last three digit like 568. And assign 
> to consistent circle based the clock wise*
>
> *Am getting the problem suppose I have two server node like 
> 192.168.9.23:11211, 192.168.9.24:11212  *
>
> *And after converting to hash code am getting the consortium id like this*
>
> *8695869568 for node1 (192.168.9.23:11211)*
>
> *8695869569 for node 2(192.168.9.24:11212)*
>
> *Here if am taking the last three digit it will come like 568,569 so it 
> is very nearest number.*
>
> *How I can equally distribute the node in consistent circle I don’t want 
> two nodes staying in nearest range of number.*
>
> *The main important point is my hash code should not change when adding a 
> new node or removing the node*
>
>
> *i have added the graphical representation of consistent algorithm below 
> am getting the out put like this 
> *
>
> *i need my consistent circle like this
> *
>
>
> <https://lh5.googleusercontent.com/-uz5Hd7TdQpM/UiWqQ3BswkI/AAAAAAAAABw/WMyxKE7mxVg/s1600/true.png>
>
> *if any one know the appropriate formula for allocating the nodes in 
> circle please help me
> *
>
> *currently am getting the allocation of id like this in consistent circle 
> *
>
>
> <https://lh3.googleusercontent.com/-0TTLTPrQrUY/UiWqFbY0c_I/AAAAAAAAABo/IaywfsHE9E8/s1600/wrong.png>
>
> * 
> *
>
> * *
>  
> -- 
>  
> --- 
> You received this message because you are subscribed to the Google Groups 
> "memcached" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to memcached+...@googlegroups.com <javascript:>.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"memcached" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to memcached+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to