package

org.apache.helix

Provide the classes necessary to create a Helix cluster manager

General flow

 manager = HelixManagerFactory.getManagerForROLE(); ROLE can be participant, spectator or a controller
manager.connect(); manager.addSOMEListener(); After connect the subsequent interactions will be via listener onChange callbacks There will be 3 scenarios for onChange callback, which can be determined using NotificationContext.type INIT -> will be invoked the first time the listener is added CALLBACK -> will be invoked due to datachange in the property value FINALIZE -> will be invoked when listener is removed or session expires manager.disconnect()
Default implementations available

Interfaces

BaseDataAccessor<T>  
ClusterMessagingService Provides the ability to
  • Send message to a specific component in the cluster[ participant, controller, Spectator(probably not needed) ]
  • Broadcast message to all participants
  • Send message to instances that hold a specific resource
  • Asynchronous request response api. 
  • ConfigChangeListener This interface is deprecated. replaced by InstanceConfigChangeListener  
    ControllerChangeListener  
    CurrentStateChangeListener  
    ExternalViewChangeListener  
    HashFunction  
    HealthStateChangeListener  
    HelixAdmin  
    HelixConstants  
    HelixDataAccessor Interface used to interact with Helix Data Types like IdealState, Config, LiveInstance, Message, ExternalView etc PropertyKey represent the HelixData type. 
    HelixManager Class that represents the Helix Agent. 
    IdealStateChangeListener  
    InstanceConfigChangeListener  
    LiveInstanceChangeListener  
    LiveInstanceInfoProvider  
    MessageListener  
    PreConnectCallback  
    ScopedConfigChangeListener  

    Classes

    AccessOption  
    CMConnector  
    ConfigAccessor  
    Criteria  
    EspressoResource  
    EspressoStorageMockNode  
    EspressoStorageMockStateModelFactory  
    EspressoStorageMockStateModelFactory.EspressoStorageMockStateModel  
    ExternalCommand  
    FnvHashFunction  
    GroupCommit  
    HelixManagerFactory  
    HelixManagerProperties hold helix-manager properties read from helix-core/src/main/resources/cluster-manager.properties  
    HelixProperty A wrapper class for ZNRecord. 
    HelixTimerTask  
    MockEspressoService  
    MockNode  
    MockNodeFactory  
    MockRunner Hello world!  
    NotificationContext  
    PropertyKey  
    PropertyKey.Builder  
    PropertyPathConfig  
    StopServiceResource  
    ZNRecord Generic Record Format to store data at a Node This can be used to store simpleFields mapFields listFields  
    ZNRecordAssembler  
    ZNRecordBucketizer  
    ZNRecordDelta  
    ZNRecordUpdater  

    Enums

    Criteria.DataSource  
    HelixConstants.ChangeType  
    HelixConstants.ClusterConfigType  
    HelixConstants.StateModelToken  
    HelixDefinedState helix defined states ERROR : when errors happen during state transitions, transit to ERROR state participant will also invoke state-model.on-err(), ignore errors in state-model.on-err() when drop resource in ERROR state and not disabled, controller sends ERROR->DROPPED transition if errors happen in ERROR->DROPPED transition, participant will disable resource/partition when disable resource/partition in ERROR state, resource/partition will be marked disabled but controller not send any transitions when reset resource/partition in ERROR state and not disabled controller send ERROR->initial-state transition if errors happen in ERROR->initial-state transition, remain in ERROR state DROPPED : when drop resource in a non-ERROR state and not disabled controller sends all the transitions from current-state to initial-state then sends initial-state->DROPPED transition 
    HelixProperty.HelixPropertyAttribute  
    InstanceType CONTROLLER: cluster managing component is a controller PARTICIPANT: participate in the cluster state changes SPECTATOR: interested in the state changes in the cluster CONTROLLER_PARTICIPANT: special participant that competes for the leader of CONTROLLER_CLUSTER used in cluster controller of distributed mode {@HelixControllerMain }  
    NotificationContext.MapKey  
    NotificationContext.Type  
    PropertyType  
    ZNRecordDelta.MergeOperation  

    Exceptions