Class TopologyInfo
java.lang.Object
org.infinispan.distribution.topologyaware.TopologyInfo
This class holds the topology hierarchy of a cache's members and estimates for owned segments.
- Since:
- 5.2
- Author:
- Dan Berindei
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classBase class for locations.static classstatic classstatic classstatic class -
Constructor Summary
ConstructorsConstructorDescriptionTopologyInfo(int numSegments, int numOwners, Collection<Address> members, Map<Address, Float> capacityFactors) -
Method Summary
Modifier and TypeMethodDescriptionfloatcomputeTotalCapacity(Collection<Address> nodes, Map<Address, Float> capacityFactors) booleanduplicateLocation(TopologyLevel level, Collection<Address> addresses, Address candidate, boolean excludeCandidate) formatLocation(DecimalFormat df, TopologyInfo.Location location, String prefix) intintgetDistinctLocationsCount(TopologyLevel level, Collection<Address> addresses) floatgetExpectedOwnedSegments(Address address) floatgetExpectedPrimarySegments(Address address) getLocationId(TopologyLevel level, Address address) intgetMachineIndex(Address address) getMachineNodes(String site, String rack, String machine) intgetRackIndex(Address address) getRackMachines(String site, String rack) getRackNodes(String site, String rack) intgetSiteIndex(Address address) getSiteNodes(String site) getSiteRacks(String site) toString()
-
Constructor Details
-
TopologyInfo
public TopologyInfo(int numSegments, int numOwners, Collection<Address> members, Map<Address, Float> capacityFactors)
-
-
Method Details
-
getDistinctLocationsCount
-
getDistinctLocationsCount
-
duplicateLocation
public boolean duplicateLocation(TopologyLevel level, Collection<Address> addresses, Address candidate, boolean excludeCandidate) -
getLocationId
-
getSiteNodes
-
getRackNodes
-
getMachineNodes
-
getAllSites
-
getSiteRacks
-
getRackMachines
-
toString
-
formatLocation
-
computeTotalCapacity
-
getExpectedPrimarySegments
-
getExpectedOwnedSegments
-
getSiteIndex
-
getRackIndex
-
getMachineIndex
-