org.apache.hadoop.yarn.server.nodemanager.containermanager
Class AuxServices
java.lang.Object
org.apache.hadoop.service.AbstractService
org.apache.hadoop.yarn.server.nodemanager.containermanager.AuxServices
- All Implemented Interfaces:
- Closeable, org.apache.hadoop.service.Service, org.apache.hadoop.service.ServiceStateChangeListener, org.apache.hadoop.yarn.event.EventHandler<AuxServicesEvent>
public class AuxServices
- extends org.apache.hadoop.service.AbstractService
- implements org.apache.hadoop.service.ServiceStateChangeListener, org.apache.hadoop.yarn.event.EventHandler<AuxServicesEvent>
| Nested classes/interfaces inherited from interface org.apache.hadoop.service.Service |
org.apache.hadoop.service.Service.STATE |
| Methods inherited from class org.apache.hadoop.service.AbstractService |
close, getBlockers, getConfig, getFailureCause, getFailureState, getLifecycleHistory, getName, getServiceState, getStartTime, init, isInState, noteFailure, putBlocker, registerGlobalListener, registerServiceListener, removeBlocker, setConfig, start, stop, toString, unregisterGlobalListener, unregisterServiceListener, waitForServiceToStop |
serviceMap
protected final Map<String,org.apache.hadoop.yarn.server.api.AuxiliaryService> serviceMap
serviceMetaData
protected final Map<String,ByteBuffer> serviceMetaData
AuxServices
public AuxServices()
addService
protected final void addService(String name,
org.apache.hadoop.yarn.server.api.AuxiliaryService service)
getMetaData
public Map<String,ByteBuffer> getMetaData()
- 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.
getMetaData
public Map<String,ByteBuffer> getMetaData(org.apache.hadoop.yarn.server.api.ContainerInitializationContext ctx)
serviceInit
public void serviceInit(org.apache.hadoop.conf.Configuration conf)
throws Exception
- Overrides:
serviceInit in class org.apache.hadoop.service.AbstractService
- Throws:
Exception
serviceStart
public void serviceStart()
throws Exception
- Overrides:
serviceStart in class org.apache.hadoop.service.AbstractService
- Throws:
Exception
serviceStop
public void serviceStop()
throws Exception
- Overrides:
serviceStop in class org.apache.hadoop.service.AbstractService
- Throws:
Exception
stateChanged
public void stateChanged(org.apache.hadoop.service.Service service)
- Specified by:
stateChanged in interface org.apache.hadoop.service.ServiceStateChangeListener
handle
public void handle(AuxServicesEvent event)
- Specified by:
handle in interface org.apache.hadoop.yarn.event.EventHandler<AuxServicesEvent>
Copyright © 2014 Apache Software Foundation. All Rights Reserved.