org.apache.hadoop.yarn.server.nodemanager.containermanager
Class AuxServices

java.lang.Object
  extended by org.apache.hadoop.yarn.service.AbstractService
      extended by org.apache.hadoop.yarn.server.nodemanager.containermanager.AuxServices
All Implemented Interfaces:
org.apache.hadoop.yarn.event.EventHandler<AuxServicesEvent>, org.apache.hadoop.yarn.service.Service, org.apache.hadoop.yarn.service.ServiceStateChangeListener

public class AuxServices
extends org.apache.hadoop.yarn.service.AbstractService
implements org.apache.hadoop.yarn.service.ServiceStateChangeListener, org.apache.hadoop.yarn.event.EventHandler<AuxServicesEvent>


Nested Class Summary
static interface AuxServices.AuxiliaryService
           
 
Nested classes/interfaces inherited from interface org.apache.hadoop.yarn.service.Service
org.apache.hadoop.yarn.service.Service.STATE
 
Field Summary
protected  Map<String,AuxServices.AuxiliaryService> serviceMap
           
protected  Map<String,ByteBuffer> serviceMeta
           
 
Constructor Summary
AuxServices()
           
 
Method Summary
protected  void addService(String name, AuxServices.AuxiliaryService service)
           
 Map<String,ByteBuffer> getMeta()
           
 void handle(AuxServicesEvent event)
           
 void init(org.apache.hadoop.conf.Configuration conf)
           
 void start()
           
 void stateChanged(org.apache.hadoop.yarn.service.Service service)
           
 void stop()
           
 
Methods inherited from class org.apache.hadoop.yarn.service.AbstractService
getConfig, getName, getServiceState, getStartTime, register, unregister
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serviceMap

protected final Map<String,AuxServices.AuxiliaryService> serviceMap

serviceMeta

protected final Map<String,ByteBuffer> serviceMeta
Constructor Detail

AuxServices

public AuxServices()
Method Detail

addService

protected final void addService(String name,
                                AuxServices.AuxiliaryService service)

getMeta

public Map<String,ByteBuffer> getMeta()
Returns:
the meta data for all registered services, that have been started. If a service has not been started no metadata will be available. The key is the name of the service as defined in the configuration.

init

public void init(org.apache.hadoop.conf.Configuration conf)
Specified by:
init in interface org.apache.hadoop.yarn.service.Service
Overrides:
init in class org.apache.hadoop.yarn.service.AbstractService

start

public void start()
Specified by:
start in interface org.apache.hadoop.yarn.service.Service
Overrides:
start in class org.apache.hadoop.yarn.service.AbstractService

stop

public void stop()
Specified by:
stop in interface org.apache.hadoop.yarn.service.Service
Overrides:
stop in class org.apache.hadoop.yarn.service.AbstractService

stateChanged

public void stateChanged(org.apache.hadoop.yarn.service.Service service)
Specified by:
stateChanged in interface org.apache.hadoop.yarn.service.ServiceStateChangeListener

handle

public void handle(AuxServicesEvent event)
Specified by:
handle in interface org.apache.hadoop.yarn.event.EventHandler<AuxServicesEvent>


Copyright © 2012 Apache Software Foundation. All Rights Reserved.