public class

LockManagerRebalancer

extends Object
implements HelixRebalancer
java.lang.Object
   ↳ org.apache.helix.userdefinedrebalancer.LockManagerRebalancer

Summary

Public Constructors
LockManagerRebalancer()
Public Methods
ResourceAssignment computeResourceMapping(RebalancerConfig rebalancerConfig, ResourceAssignment prevAssignment, Cluster cluster, ResourceCurrentState currentState)
This rebalancer is invoked whenever there is a change in the cluster, including when new participants join or leave, or the configuration of any participant changes.
void init(HelixManager manager, ControllerContextProvider contextProvider)
Initialize the rebalancer with a HelixManager and ControllerContextProvider if necessary
[Expand]
Inherited Methods
From class java.lang.Object
From interface org.apache.helix.controller.rebalancer.HelixRebalancer

Public Constructors

public LockManagerRebalancer ()

Public Methods

public ResourceAssignment computeResourceMapping (RebalancerConfig rebalancerConfig, ResourceAssignment prevAssignment, Cluster cluster, ResourceCurrentState currentState)

This rebalancer is invoked whenever there is a change in the cluster, including when new participants join or leave, or the configuration of any participant changes. It is written specifically to handle assignment of locks to nodes under the very simple lock-unlock state model.

Parameters
rebalancerConfig the properties of the resource for which a mapping will be computed
prevAssignment the previous ResourceAssignment of this cluster, or null if none
cluster complete snapshot of the cluster
currentState the current states of all partitions

public void init (HelixManager manager, ControllerContextProvider contextProvider)

Initialize the rebalancer with a HelixManager and ControllerContextProvider if necessary

Parameters
contextProvider An object that supports getting and setting context across pipeline runs