public class ConfigurableAuxServices
extends org.apache.hadoop.service.AbstractService
implements org.apache.hadoop.service.ServiceStateChangeListener
auxServicesPropName and
uses it to determine the auxiliary service classes to instantiate.
Since this is meant to be an extensibility feature, the calling code should
add this instance as the first one to its service list. This will ensure
that the externally plugged in services are initialized first as they may
be setting up critical resources on top of which rest of the stack should
be built. For e.g., an external service might try to create volumes on top
of which directories need to be created.
Note: The code has been taken from @link{AuxServices}.| Constructor and Description |
|---|
ConfigurableAuxServices(String name,
String auxServicesPropName) |
| Modifier and Type | Method and Description |
|---|---|
void |
serviceInit(org.apache.hadoop.conf.Configuration conf) |
void |
serviceStart() |
void |
serviceStop() |
void |
stateChanged(org.apache.hadoop.service.Service service) |
close, getBlockers, getConfig, getFailureCause, getFailureState, getLifecycleHistory, getName, getServiceState, getStartTime, init, isInState, noteFailure, putBlocker, registerGlobalListener, registerServiceListener, removeBlocker, setConfig, start, stop, toString, unregisterGlobalListener, unregisterServiceListener, waitForServiceToStoppublic void serviceInit(org.apache.hadoop.conf.Configuration conf)
throws Exception
serviceInit in class org.apache.hadoop.service.AbstractServiceExceptionpublic void serviceStart()
throws Exception
serviceStart in class org.apache.hadoop.service.AbstractServiceExceptionpublic void serviceStop()
throws Exception
serviceStop in class org.apache.hadoop.service.AbstractServiceExceptionpublic void stateChanged(org.apache.hadoop.service.Service service)
stateChanged in interface org.apache.hadoop.service.ServiceStateChangeListenerCopyright © 2014 Apache Software Foundation. All Rights Reserved.