|
Oracle® Coherence Java API Reference Release 3.7.1.0 E22843-01 |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface DistributionManager
A DistributionManager coordinates the distribution of partitions for a partitioned service. The DistributionManager relies on a pluggable PartitionAssignmentStrategy
to analyze the current state of the partition usage, and formulate a desired distribution plan. The DistributionManager is responsible for gathering and providing to the strategy the state necessary to make distribution decisions, as well as collecting and enacting the formulated distribution recommendations.
The DistributionManager provides a consistent and stable view of Service-related state for the duration of the call to PartitionAssignmentStrategy.analyzeDistribution()
.
Method Summary | |
---|---|
Member |
getMember(int nMemberId) Return the ownership-enabled service member with the specified mini-id, or null if the member does not exist. |
PartitionSet |
getOwnedPartitions(Member member, int iStore) Return the set of partitions for which the specified member owns the specified storage index (replica). |
java.util.Set |
getOwnershipLeavingMembers() Return the set of ownership-enabled members in the partitioned service that are in the process of leaving. |
java.util.Set |
getOwnershipMembers() Return the set of ownership-enabled members in the partitioned service. |
Ownership |
getPartitionOwnership(int nPartition) Return the Ownership information for the specified partition. |
PartitionedService |
getService() Return the partitioned service for which this DistributionManager coordinates the distribution. |
void |
suggest(PartitionSet parts, Ownership ownership) Suggest a distribution change for the specified set of partitions, indicating either primary or backup transfer (or both). |
Method Detail |
---|
PartitionedService getService()
Member getMember(int nMemberId)
nMemberId
- the mini-idjava.util.Set getOwnershipMembers()
java.util.Set getOwnershipLeavingMembers()
PartitionSet getOwnedPartitions(Member member, int iStore)
member
- the member to determine the the ownership foriStore
- the storage index (zero for primary)java.lang.IllegalArgumentException
- if the backup number is non-positive or greater than the backup count for this partitioned serviceOwnership getPartitionOwnership(int nPartition)
nPartition
- the partition to return the ownership forjava.lang.IllegalArgumentException
- if the partition number is negative or greater than the partition count for this partitioned servicevoid suggest(PartitionSet parts, Ownership ownership)
Note: this method does not in any way enforce or guarantee that the specified transfers are performed; it merely provides advice
parts
- the set of partitions to perform distribution onownership
- the desired ownership
|
Oracle® Coherence Java API Reference Release 3.7.1.0 E22843-01 |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |