Modifier and Type | Class and Description |
---|---|
static class |
TabletMap.HostShardPair
Simple class to hold UUID of a host and a shard number.
|
static class |
TabletMap.KeyspaceTableNamePair
Simple keyspace name and table name pair.
|
static class |
TabletMap.Tablet
Represents a single tablet created from tablets-routing-v1 custom payload.
|
static class |
TabletMap.TabletSet
Set of tablets bundled with ReadWriteLock to allow concurrent modification for different sets.
|
Constructor and Description |
---|
TabletMap(com.datastax.driver.core.Cluster.Manager cluster,
ConcurrentMap<TabletMap.KeyspaceTableNamePair,TabletMap.TabletSet> mapping) |
Modifier and Type | Method and Description |
---|---|
static TabletMap |
emptyMap(com.datastax.driver.core.Cluster.Manager cluster) |
Map<TabletMap.KeyspaceTableNamePair,TabletMap.TabletSet> |
getMapping()
Returns the mapping of tables to their tablets.
|
TupleType |
getPayloadInnerTuple() |
TupleType |
getPayloadOuterTuple() |
List<Host> |
getReplicas(String keyspace,
String table,
long token)
Finds hosts that have replicas for a given table and token combination.
|
TypeCodec<TupleValue> |
getTabletPayloadCodec() |
void |
removeTableMappings(String keyspace) |
void |
removeTableMappings(String keyspace,
String table) |
void |
removeTableMappings(TabletMap.KeyspaceTableNamePair key) |
public TabletMap(com.datastax.driver.core.Cluster.Manager cluster, ConcurrentMap<TabletMap.KeyspaceTableNamePair,TabletMap.TabletSet> mapping)
public static TabletMap emptyMap(com.datastax.driver.core.Cluster.Manager cluster)
public Map<TabletMap.KeyspaceTableNamePair,TabletMap.TabletSet> getMapping()
TabletMap.TabletSet
as value type.public List<Host> getReplicas(String keyspace, String table, long token)
keyspace
- the keyspace that table is intable
- the table nametoken
- the token to look forpublic TupleType getPayloadOuterTuple()
public TupleType getPayloadInnerTuple()
public TypeCodec<TupleValue> getTabletPayloadCodec()
public void removeTableMappings(TabletMap.KeyspaceTableNamePair key)
public void removeTableMappings(String keyspace)
Copyright © 2012–2025. All rights reserved.