public interface InternalPartition
Partition but it is optimized for internal
usage, so it exposes method not meant for regular Hazelcast users.
The InternalPartition provides access to information about a partition, most importantly the addresses of the
replica's and this information will be updated. So one can cache the InternalPartition and keep asking for
partition information.| Modifier and Type | Field and Description |
|---|---|
static int |
MAX_BACKUP_COUNT |
static int |
MAX_REPLICA_COUNT |
| Modifier and Type | Method and Description |
|---|---|
Address |
getOwnerOrNull()
Returns the Address of the owner of this partition.
|
int |
getPartitionId()
Returns the partition id.
|
Address |
getReplicaAddress(int replicaIndex)
Returns Address of the replica.
|
boolean |
isMigrating()
Checks if there currently is a migration going on in this partition.
|
boolean |
isOwnerOrBackup(Address address)
Checks if given address is owner of primary or backup of this partition.
|
static final int MAX_REPLICA_COUNT
static final int MAX_BACKUP_COUNT
int getPartitionId()
Address getOwnerOrNull()
boolean isMigrating()
Address getReplicaAddress(int replicaIndex)
replicaIndex - the index of the replica.ArrayIndexOutOfBoundsException - when replica index is out of boundsboolean isOwnerOrBackup(Address address)
address - owner addressCopyright © 2015 Hazelcast, Inc.. All Rights Reserved.