public abstract class

StatelessParticipantService

extends AbstractParticipantService
java.lang.Object
   ↳ com.google.common.util.concurrent.AbstractService
     ↳ org.apache.helix.participant.AbstractParticipantService
       ↳ org.apache.helix.provisioning.participant.StatelessParticipantService
Known Direct Subclasses

Summary

Public Constructors
StatelessParticipantService(HelixConnection connection, ClusterId clusterId, ParticipantId participantId, String serviceName)
Public Methods
String getName()
Get the name of this stateless service
Protected Methods
abstract void goOffine()
Invoked when this service is instructed to go offline
abstract void goOnline()
Invoked when this service is instructed to go online
void init()
Initialize the participant.
abstract void init(ServiceConfig serviceConfig)
Initialize the service with a configuration
[Expand]
Inherited Methods
From class org.apache.helix.participant.AbstractParticipantService
From class com.google.common.util.concurrent.AbstractService
From class java.lang.Object
From interface com.google.common.util.concurrent.Service

Public Constructors

public StatelessParticipantService (HelixConnection connection, ClusterId clusterId, ParticipantId participantId, String serviceName)

Public Methods

public String getName ()

Get the name of this stateless service

Returns
  • service name

Protected Methods

protected abstract void goOffine ()

Invoked when this service is instructed to go offline

protected abstract void goOnline ()

Invoked when this service is instructed to go online

protected void init ()

Initialize the participant. For example, here is where you can

  • Read configuration of the cluster,resource, node
  • Read configuration of the cluster,resource, node register a state machine:

    HelixParticipant participant = getParticipant(); participant.getStateMachineEngine().registerStateModelFactory(stateModelDefId, factory);

This code is called after connecting to zookeeper but before creating the liveinstance.

protected abstract void init (ServiceConfig serviceConfig)

Initialize the service with a configuration