Package org.apache.cassandra.locator
Class TokenMetadata.Topology
java.lang.Object
org.apache.cassandra.locator.TokenMetadata.Topology
- Enclosing class:
- TokenMetadata
Tracks the assignment of racks and endpoints in each datacenter for all the "normal" endpoints
in this TokenMetadata. This allows faster calculation of endpoints in NetworkTopologyStrategy.
-
Method Summary
Modifier and TypeMethodDescriptioncom.google.common.collect.Multimap<String,InetAddressAndPort> com.google.common.collect.ImmutableMap<String,com.google.common.collect.ImmutableMultimap<String, InetAddressAndPort>>
-
Method Details
-
getDatacenterEndpoints
- Returns:
- multi-map of DC to endpoints in that DC
-
getDatacenterRacks
public com.google.common.collect.ImmutableMap<String,com.google.common.collect.ImmutableMultimap<String, getDatacenterRacks()InetAddressAndPort>> - Returns:
- map of DC to multi-map of rack to endpoints in that rack
-
getLocation
- Returns:
- The DC and rack of the given endpoint.
-