public class ResourceManager extends CompositeService implements Recoverable
Modifier and Type | Class and Description |
---|---|
static class |
ResourceManager.ApplicationAttemptEventDispatcher |
static class |
ResourceManager.ApplicationEventDispatcher |
static class |
ResourceManager.NodeEventDispatcher |
static class |
ResourceManager.RMContainerPreemptEventDispatcher |
static class |
ResourceManager.SchedulerEventDispatcher |
CompositeService.CompositeServiceShutdownHook
Service.STATE
Modifier and Type | Field and Description |
---|---|
protected AMRMTokenSecretManager |
amRmTokenSecretManager |
protected ApplicationACLsManager |
applicationACLsManager |
protected ClientToAMTokenSecretManagerInRM |
clientToAMSecretManager |
static long |
clusterTimeStamp |
protected RMContainerTokenSecretManager |
containerTokenSecretManager |
protected ApplicationMasterService |
masterService |
protected NMLivelinessMonitor |
nmLivelinessMonitor |
protected NMTokenSecretManagerInRM |
nmTokenSecretManager |
protected NodesListManager |
nodesListManager |
protected QueueACLsManager |
queueACLsManager |
protected ResourceTrackerService |
resourceTracker |
protected RMAppManager |
rmAppManager |
protected RMContext |
rmContext |
protected RMDelegationTokenSecretManager |
rmDTSecretManager |
protected ResourceScheduler |
scheduler |
static int |
SHUTDOWN_HOOK_PRIORITY
Priority of the ResourceManager shutdown hook.
|
STOP_ONLY_STARTED_SERVICES
Constructor and Description |
---|
ResourceManager() |
addIfService, addService, getServices, removeService
close, getBlockers, getConfig, getFailureCause, getFailureState, getLifecycleHistory, getName, getServiceState, getStartTime, init, isInState, noteFailure, putBlocker, registerGlobalListener, registerServiceListener, removeBlocker, setConfig, start, stop, toString, unregisterGlobalListener, unregisterServiceListener, waitForServiceToStop
public static final int SHUTDOWN_HOOK_PRIORITY
public static final long clusterTimeStamp
protected ClientToAMTokenSecretManagerInRM clientToAMSecretManager
protected RMContainerTokenSecretManager containerTokenSecretManager
protected NMTokenSecretManagerInRM nmTokenSecretManager
protected AMRMTokenSecretManager amRmTokenSecretManager
protected ResourceScheduler scheduler
protected ApplicationMasterService masterService
protected NMLivelinessMonitor nmLivelinessMonitor
protected NodesListManager nodesListManager
protected RMAppManager rmAppManager
protected ApplicationACLsManager applicationACLsManager
protected QueueACLsManager queueACLsManager
protected RMDelegationTokenSecretManager rmDTSecretManager
protected RMContext rmContext
protected ResourceTrackerService resourceTracker
public RMContext getRMContext()
protected void serviceInit(Configuration conf) throws Exception
AbstractService
AbstractService.init(Configuration)
prevents re-entrancy.
The base implementation checks to see if the subclass has created
a new configuration instance, and if so, updates the base class valueserviceInit
in class CompositeService
conf
- configurationException
- on a failure -these will be caught,
possibly wrapped, and wil; trigger a service stopprotected QueueACLsManager createQueueACLsManager(ResourceScheduler scheduler, Configuration conf)
protected void setRMStateStore(RMStateStore rmStore)
protected RMContainerTokenSecretManager createContainerTokenSecretManager(Configuration conf)
protected NMTokenSecretManagerInRM createNMTokenSecretManager(Configuration conf)
protected EventHandler<SchedulerEvent> createSchedulerEventDispatcher()
protected Dispatcher createDispatcher()
protected AMRMTokenSecretManager createAMRMTokenSecretManager(Configuration conf)
protected ResourceScheduler createScheduler()
protected ApplicationMasterLauncher createAMLauncher()
protected AMLivelinessMonitor createAMLivelinessMonitor()
protected DelegationTokenRenewer createDelegationTokenRenewer()
protected RMAppManager createRMAppManager()
protected static void validateConfigs(Configuration conf)
protected void startWepApp()
protected void serviceStart() throws Exception
AbstractService
AbstractService.start()
prevents re-entrancy.serviceStart
in class CompositeService
Exception
- if needed -these will be caught,
wrapped, and trigger a service stopprotected void doSecureLogin() throws IOException
IOException
protected void serviceStop() throws Exception
AbstractService
AbstractService.stop()
prevents re-entrancy.
Implementations MUST write this to be robust against failures, including
checks for null references -and for the first failure to not stop other
attempts to shut down parts of the service.serviceStop
in class CompositeService
Exception
- if needed -these will be caught and logged.protected ResourceTrackerService createResourceTrackerService()
protected RMDelegationTokenSecretManager createRMDelegationTokenSecretManager(RMContext rmContext)
protected ClientRMService createClientRMService()
protected ApplicationMasterService createApplicationMasterService()
protected void createPolicyMonitors()
protected AdminService createAdminService(ClientRMService clientRMService, ApplicationMasterService applicationMasterService, ResourceTrackerService resourceTrackerService)
@InterfaceAudience.Private public ClientRMService getClientRMService()
@InterfaceAudience.Private public ResourceScheduler getResourceScheduler()
@InterfaceAudience.Private public ResourceTrackerService getResourceTrackerService()
@InterfaceAudience.Private public ApplicationMasterService getApplicationMasterService()
@InterfaceAudience.Private public ApplicationACLsManager getApplicationACLsManager()
@InterfaceAudience.Private public QueueACLsManager getQueueACLsManager()
@InterfaceAudience.Private public RMContainerTokenSecretManager getRMContainerTokenSecretManager()
@InterfaceAudience.Private public NMTokenSecretManagerInRM getRMNMTokenSecretManager()
@InterfaceAudience.Private public AMRMTokenSecretManager getAMRMTokenSecretManager()
public void recover(RMStateStore.RMState state) throws Exception
recover
in interface Recoverable
Exception
public static void main(String[] argv)
Copyright © 2013 Apache Software Foundation. All rights reserved.