public interface

RebalancerConfig

org.apache.helix.controller.rebalancer.config.RebalancerConfig
Known Indirect Subclasses

Class Overview

Defines the state available to a rebalancer. The most common use case is to use a PartitionedRebalancerConfig or a subclass and set up a resource with it. A rebalancer configuration, at a minimum, is aware of subunits of a resource, the state model to follow, and how the configuration should be serialized.

Summary

Public Methods
abstract String getParticipantGroupTag()
Get the tag, if any, that participants must have in order to serve this resource
abstract RebalancerRef getRebalancerRef()
Get a reference to the class used to rebalance this resource
abstract ResourceId getResourceId()
Get the resource to rebalance
abstract Class<? extends StringSerializer> getSerializerClass()
Get the serializer for this config
abstract StateModelDefId getStateModelDefId()
Get the state model definition that the resource follows
abstract StateModelFactoryId getStateModelFactoryId()
Get the state model factory of this resource
abstract Partition getSubUnit(PartitionId subUnitId)
Get a specific subunit
abstract Set<? extends PartitionId> getSubUnitIdSet()
Get the subunits of the resource (e.g.
abstract Map<? extends PartitionId, ? extends Partition> getSubUnitMap()
Get a map of resource partition identifiers to partitions.

Public Methods

public abstract String getParticipantGroupTag ()

Get the tag, if any, that participants must have in order to serve this resource

Returns
  • participant group tag, or null

public abstract RebalancerRef getRebalancerRef ()

Get a reference to the class used to rebalance this resource

Returns
  • RebalancerRef

public abstract ResourceId getResourceId ()

Get the resource to rebalance

Returns
  • resource id

public abstract Class<? extends StringSerializer> getSerializerClass ()

Get the serializer for this config

Returns
  • StringSerializer class object

public abstract StateModelDefId getStateModelDefId ()

Get the state model definition that the resource follows

Returns
  • state model definition id

public abstract StateModelFactoryId getStateModelFactoryId ()

Get the state model factory of this resource

Returns
  • state model factory id

public abstract Partition getSubUnit (PartitionId subUnitId)

Get a specific subunit

Parameters
subUnitId the id of the subunit
Returns
  • SubUnit

public abstract Set<? extends PartitionId> getSubUnitIdSet ()

Get the subunits of the resource (e.g. partitions)

Returns
  • set of subunit ids

public abstract Map<? extends PartitionId, ? extends Partition> getSubUnitMap ()

Get a map of resource partition identifiers to partitions. A partition is a subunit of a resource, e.g. a subtask of a task

Returns
  • map of (subunit id, subunit) pairs