Uses of Class
org.apache.cassandra.locator.TokenMetadata
-
Packages that use TokenMetadata Package Description org.apache.cassandra.dht org.apache.cassandra.dht.tokenallocator org.apache.cassandra.locator org.apache.cassandra.service -
-
Uses of TokenMetadata in org.apache.cassandra.dht
Fields in org.apache.cassandra.dht declared as TokenMetadata Modifier and Type Field Description protected TokenMetadata
BootStrapper. tokenMetadata
Methods in org.apache.cassandra.dht with parameters of type TokenMetadata Modifier and Type Method Description static EndpointsByReplica
RangeStreamer. calculateRangesToFetchWithPreferredEndpoints(java.util.function.BiFunction<InetAddressAndPort,EndpointsForRange,EndpointsForRange> snitchGetSortedListByProximity, AbstractReplicationStrategy strat, ReplicaCollection<?> fetchRanges, boolean useStrictConsistency, TokenMetadata tmdBefore, TokenMetadata tmdAfter, java.lang.String keyspace, java.util.Collection<RangeStreamer.SourceFilter> sourceFilters)
Get a map of all ranges and the source that will be cleaned up once this bootstrapped node is added for the given ranges.static java.util.Collection<Token>
BootStrapper. getBootstrapTokens(TokenMetadata metadata, InetAddressAndPort address, long schemaWaitDelay)
if initialtoken was specified, use that (split on comma).static java.util.Collection<Token>
BootStrapper. getRandomTokens(TokenMetadata metadata, int numTokens)
Constructors in org.apache.cassandra.dht with parameters of type TokenMetadata Constructor Description BootStrapper(InetAddressAndPort address, java.util.Collection<Token> tokens, TokenMetadata tmd)
RangeStreamer(TokenMetadata metadata, java.util.Collection<Token> tokens, InetAddressAndPort address, StreamOperation streamOperation, boolean useStrictConsistency, IEndpointSnitch snitch, StreamStateStore stateStore, boolean connectSequentially, int connectionsPerHost)
-
Uses of TokenMetadata in org.apache.cassandra.dht.tokenallocator
Methods in org.apache.cassandra.dht.tokenallocator with parameters of type TokenMetadata Modifier and Type Method Description static java.util.Collection<Token>
TokenAllocation. allocateTokens(TokenMetadata tokenMetadata, int replicas, InetAddressAndPort endpoint, int numTokens)
static java.util.Collection<Token>
TokenAllocation. allocateTokens(TokenMetadata tokenMetadata, AbstractReplicationStrategy rs, InetAddressAndPort endpoint, int numTokens)
-
Uses of TokenMetadata in org.apache.cassandra.locator
Methods in org.apache.cassandra.locator that return TokenMetadata Modifier and Type Method Description TokenMetadata
TokenMetadata. cachedOnlyTokenMap()
Return a cached TokenMetadata with only tokenToEndpointMap, i.e., the same as cloneOnlyTokenMap but uses a cached copy that is invalided when the ring changes, so in the common case no extra locking is required.TokenMetadata
TokenMetadata. cloneAfterAllLeft()
Create a copy of TokenMetadata with tokenToEndpointMap reflecting situation after all current leave operations have finished.TokenMetadata
TokenMetadata. cloneAfterAllSettled()
Create a copy of TokenMetadata with tokenToEndpointMap reflecting situation after all current leave, and move operations have finished.TokenMetadata
TokenMetadata. cloneOnlyTokenMap()
Create a copy of TokenMetadata with only tokenToEndpointMap.TokenMetadata
TokenMetadata. cloneWithNewPartitioner(IPartitioner newPartitioner)
To be used by tests only (viaStorageService.setPartitionerUnsafe(org.apache.cassandra.dht.IPartitioner)
).Methods in org.apache.cassandra.locator with parameters of type TokenMetadata Modifier and Type Method Description abstract EndpointsForRange
AbstractReplicationStrategy. calculateNaturalReplicas(Token searchToken, TokenMetadata tokenMetadata)
Calculate the natural endpoints for the given token.EndpointsForRange
LocalStrategy. calculateNaturalReplicas(Token token, TokenMetadata metadata)
EndpointsForRange
NetworkTopologyStrategy. calculateNaturalReplicas(Token searchToken, TokenMetadata tokenMetadata)
calculate endpoints in one pass through the tokens by tracking our progress in each DC.EndpointsForRange
SimpleStrategy. calculateNaturalReplicas(Token token, TokenMetadata metadata)
static AbstractReplicationStrategy
AbstractReplicationStrategy. createReplicationStrategy(java.lang.String keyspaceName, java.lang.Class<? extends AbstractReplicationStrategy> strategyClass, TokenMetadata tokenMetadata, IEndpointSnitch snitch, java.util.Map<java.lang.String,java.lang.String> strategyOptions)
RangesByEndpoint
AbstractReplicationStrategy. getAddressReplicas(TokenMetadata metadata)
RangesAtEndpoint
AbstractReplicationStrategy. getAddressReplicas(TokenMetadata metadata, InetAddressAndPort endpoint)
RangesAtEndpoint
AbstractReplicationStrategy. getPendingAddressRanges(TokenMetadata metadata, java.util.Collection<Token> pendingTokens, InetAddressAndPort pendingAddress)
RangesAtEndpoint
AbstractReplicationStrategy. getPendingAddressRanges(TokenMetadata metadata, Token pendingToken, InetAddressAndPort pendingAddress)
EndpointsByRange
AbstractReplicationStrategy. getRangeAddresses(TokenMetadata metadata)
static void
AbstractReplicationStrategy. validateReplicationStrategy(java.lang.String keyspaceName, java.lang.Class<? extends AbstractReplicationStrategy> strategyClass, TokenMetadata tokenMetadata, IEndpointSnitch snitch, java.util.Map<java.lang.String,java.lang.String> strategyOptions)
Constructors in org.apache.cassandra.locator with parameters of type TokenMetadata Constructor Description AbstractReplicationStrategy(java.lang.String keyspaceName, TokenMetadata tokenMetadata, IEndpointSnitch snitch, java.util.Map<java.lang.String,java.lang.String> configOptions)
LocalStrategy(java.lang.String keyspaceName, TokenMetadata tokenMetadata, IEndpointSnitch snitch, java.util.Map<java.lang.String,java.lang.String> configOptions)
NetworkTopologyStrategy(java.lang.String keyspaceName, TokenMetadata tokenMetadata, IEndpointSnitch snitch, java.util.Map<java.lang.String,java.lang.String> configOptions)
SimpleStrategy(java.lang.String keyspaceName, TokenMetadata tokenMetadata, IEndpointSnitch snitch, java.util.Map<java.lang.String,java.lang.String> configOptions)
-
Uses of TokenMetadata in org.apache.cassandra.service
Methods in org.apache.cassandra.service that return TokenMetadata Modifier and Type Method Description TokenMetadata
StorageService. getTokenMetadata()
Methods in org.apache.cassandra.service with parameters of type TokenMetadata Modifier and Type Method Description static RangesByEndpoint
RangeRelocator. calculateRangesToStreamWithEndpoints(RangesAtEndpoint streamRanges, AbstractReplicationStrategy strat, TokenMetadata tmdBefore, TokenMetadata tmdAfter)
calculating endpoints to stream current ranges to if needed in some situations node will handle current ranges as part of the new ranges
-