public class RoundRobinByZoneRule extends AbstractRoundRobinRule
distinctKeyCount, taskFilter
Constructor and Description |
---|
RoundRobinByZoneRule(java.lang.Integer zoneCount) |
RoundRobinByZoneRule(java.util.Optional<java.lang.Integer> zoneCount) |
RoundRobinByZoneRule(java.util.Optional<java.lang.Integer> zoneCount,
StringMatcher taskFilter) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getKey(Protos.Offer offer)
Returns a key to round robin against from the provided
TaskInfo , or null if
none was found. |
java.lang.String |
getKey(Protos.TaskInfo task)
Returns a key to round robin against from the provided
TaskInfo , or null if
none was found. |
java.util.Collection<PlacementField> |
getPlacementFields()
Returns the
PlacementField s to which this rule applies. |
java.lang.String |
toString() |
equals, filter, hashCode
public RoundRobinByZoneRule(java.lang.Integer zoneCount)
public RoundRobinByZoneRule(java.util.Optional<java.lang.Integer> zoneCount)
public RoundRobinByZoneRule(java.util.Optional<java.lang.Integer> zoneCount, StringMatcher taskFilter)
public java.lang.String getKey(Protos.Offer offer)
AbstractRoundRobinRule
TaskInfo
, or null
if
none was found.getKey
in class AbstractRoundRobinRule
public java.lang.String getKey(Protos.TaskInfo task)
AbstractRoundRobinRule
TaskInfo
, or null
if
none was found.getKey
in class AbstractRoundRobinRule
public java.lang.String toString()
toString
in class java.lang.Object
public java.util.Collection<PlacementField> getPlacementFields()
PlacementRule
PlacementField
s to which this rule applies.