All Known Subinterfaces:
PartitionManager
public interface PartitionDistribution
The partition distribution provides the ability to obtain information about table partitions.
This interface can be used to get all partitions of a table, the location of the primary replica of a partition,
the partition for a specific table key.
Method Summary
All Methods Instance Methods Abstract Methods
Gets partition instance for provided table key.
Gets partition instance for provided table key.
Asynchronously gets partition instance for provided table key.
Asynchronously gets partition instance for provided table key.
Gets a list with all partitions.
Asynchronously gets a list with all partitions.
Gets the current location of the primary replica for the provided partition.
Asynchronously gets the current location of the primary replica for the provided partition.
Gets map with all partitions and their locations as of the time of the call.
Gets all partitions hosted by the specified node as a primary replica as of the time of the call.
Asynchronously gets map with all partitions and their locations as of the time of the call.
Asynchronously gets all partitions hosted by the specified node as a primary replica.
Method Details
partitionsAsync
Asynchronously gets a list with all partitions.
Returns:
Future with list with all partitions.
partitions
Gets a list with all partitions.
Returns:
List with all partitions.
primaryReplicasAsync
Asynchronously gets map with all partitions and their locations as of the time of the call.
Note: This assignment may become outdated if a re-assigment happens on the cluster.
Returns:
Future with map from partition to cluster node where primary replica of the partition is located as of the time of the call.
primaryReplicasAsync
Asynchronously gets all partitions hosted by the specified node as a primary replica.
Returns:
Future with list with all partitions hosted by the specified node as a primary replica.
primaryReplicas
Gets map with all partitions and their locations as of the time of the call.
Note: This assignment may become outdated if a re-assigment happens on the cluster.
Returns:
Map from partition to cluster node where primary replica of the partition is located as of the time of the call.
primaryReplicas
Gets all partitions hosted by the specified node as a primary replica as of the time of the call.
Note: This assignment may become outdated if a re-assigment happens on the cluster.
Returns:
List with all partitions hosted by the specified node as a primary replica as of the time of the call.
primaryReplicaAsync
Asynchronously gets the current location of the primary replica for the provided partition.
Note: This assignment may become outdated if a re-assigment happens on the cluster.
Parameters:
partition - Partition instance.
Returns:
Future that represents the pending completion of the operation.
See Also:
primaryReplica
Gets the current location of the primary replica for the provided partition.
Note: This assignment may become outdated if a re-assigment happens on the cluster.
Parameters:
partition - Partition instance.
Returns:
Cluster node where primary replica of provided partition is located as of the time of the call.
partitionAsync
Asynchronously gets partition instance for provided table key.
Type Parameters:
K - Key type.
Parameters:
key - Table key.
mapper - Table key mapper.
Returns:
Future with partition instance which contains provided key.
partitionAsync
Asynchronously gets partition instance for provided table key.
Parameters:
key - Table key tuple.
Returns:
Future with partition instance which contains provided key.
partition
Gets partition instance for provided table key.
Type Parameters:
K - Key type.
Parameters:
key - Table key.
mapper - Table key mapper.
Returns:
Partition instance which contains provided key.
partition
Gets partition instance for provided table key.
Parameters:
key - Table key tuple.
Returns:
Partition instance which contains provided key.