On Sun, Aug 8, 2010 at 5:21 AM, Carsten Krebs <carsten.kr...@gmx.net> wrote:
>
> I'm wondering why a TokenRange returned by describe_ring(keyspace) of the 
> thrift API just returns endpoints consisting only of an address but omits any 
> port information?
> My first thought was, this method could be used to expose some information 
> about the ring structure to the client, i.e. to do some client side load 
> balancing. But now, I'm not sure about this anymore. Additionally, when 
> looking into the code, I guess the address returned as part of the TokenRange 
> is the address of the storage service which could differ from the thrift 
> address, which in turn would make the returned endpoint useless for the 
> client.

Not just _could_ differ, is _guaranteed_ to differ.  The inter-node
protocol is not Thrift.  The returned endpoint is not useless for the
client: you had to connect to the RPC port to even make the call.  Use
the same port when connecting to the other nodes.  It is bad practice
to have RPC ports differ between nodes in the same cluster.

> What is the purpose of this method or respectively why is the port 
> information omitted?
>

Discovering which nodes are in the ring and which node claims each range.


b

Reply via email to