@ThreadSafe @Service(value=BalancingPolicy.class) @Properties(value=@Property(name="type",value="even")) public final class EvenBalancingPolicy extends AbstractComponent implements BalancingPolicy
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
TYPE |
Constructor and Description |
---|
EvenBalancingPolicy() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getType()
An identifier for the policy.
|
void |
rebalance(TaskContext context,
java.util.Collection<java.lang.String> workItems,
java.util.Collection<java.lang.String> members)
Distribute the items to the specified members.
|
activateComponent, assertValid, deactivateComponent, isValid
public static final java.lang.String TYPE
public java.lang.String getType()
BalancingPolicy
getType
in interface BalancingPolicy
public void rebalance(TaskContext context, java.util.Collection<java.lang.String> workItems, java.util.Collection<java.lang.String> members)
BalancingPolicy
rebalance
in interface BalancingPolicy
context
- The context of the task.workItems
- An array of the workItems path.members
- An array containing the eid of group members.Copyright © 2017 Red Hat. All Rights Reserved.