Is there a way to see token ranges for each node in cassandra which uses vnodes?
问题 Is there a way to see token ranges for each node in cassandra which used vnodes? I dont want to see token for each node which you get by issuing nodetool ring. I just want to see the token ranger for each node which uses vnodes. 回答1: The token ranges for a given node will be a function of a keyspace's topology. Programmatically you can use the java-driver for this using Cluster.getMetadata().getTokenRanges(keyspace, host). The following code example shows retrieving all token ranges by host