public class NodeStatusUpdaterImpl extends org.apache.hadoop.service.AbstractService implements NodeStatusUpdater
| Modifier and Type | Field and Description |
|---|---|
static String |
YARN_NODEMANAGER_DURATION_TO_TRACK_STOPPED_CONTAINERS |
| Constructor and Description |
|---|
NodeStatusUpdaterImpl(Context context,
org.apache.hadoop.yarn.event.Dispatcher dispatcher,
NodeHealthCheckerService healthChecker,
NodeManagerMetrics metrics) |
| Modifier and Type | Method and Description |
|---|---|
void |
addCompletedContainer(org.apache.hadoop.yarn.api.records.ContainerId containerId)
Add a container to the list of containers that have recently completed
|
void |
clearFinishedContainersFromCache()
Clear the list of recently completed containers
|
protected List<org.apache.hadoop.yarn.api.records.ContainerStatus> |
getContainerStatuses() |
protected org.apache.hadoop.yarn.server.api.ResourceTracker |
getRMClient() |
long |
getRMIdentifier()
Get the ResourceManager identifier received during registration
|
boolean |
isContainerRecentlyStopped(org.apache.hadoop.yarn.api.records.ContainerId containerId)
Query if a container has recently completed
|
protected boolean |
isTokenKeepAliveEnabled(org.apache.hadoop.conf.Configuration conf) |
protected void |
rebootNodeStatusUpdaterAndRegisterWithRM() |
protected void |
registerWithRM() |
void |
removeOrTrackCompletedContainersFromContext(List<org.apache.hadoop.yarn.api.records.ContainerId> containerIds) |
void |
removeVeryOldStoppedContainersFromCache() |
void |
sendOutofBandHeartBeat()
Schedule a heartbeat to the ResourceManager outside of the normal,
periodic heartbeating process.
|
protected void |
serviceInit(org.apache.hadoop.conf.Configuration conf) |
protected void |
serviceStart() |
protected void |
serviceStop() |
protected void |
startStatusUpdater() |
protected void |
stopRMProxy() |
close, getBlockers, getConfig, getFailureCause, getFailureState, getLifecycleHistory, getName, getServiceState, getStartTime, init, isInState, noteFailure, putBlocker, registerGlobalListener, registerServiceListener, removeBlocker, setConfig, start, stop, toString, unregisterGlobalListener, unregisterServiceListener, waitForServiceToStoppublic static final String YARN_NODEMANAGER_DURATION_TO_TRACK_STOPPED_CONTAINERS
public NodeStatusUpdaterImpl(Context context, org.apache.hadoop.yarn.event.Dispatcher dispatcher, NodeHealthCheckerService healthChecker, NodeManagerMetrics metrics)
protected void serviceInit(org.apache.hadoop.conf.Configuration conf)
throws Exception
serviceInit in class org.apache.hadoop.service.AbstractServiceExceptionprotected void serviceStart()
throws Exception
serviceStart in class org.apache.hadoop.service.AbstractServiceExceptionprotected void serviceStop()
throws Exception
serviceStop in class org.apache.hadoop.service.AbstractServiceExceptionprotected void rebootNodeStatusUpdaterAndRegisterWithRM()
protected void stopRMProxy()
@InterfaceAudience.Private protected boolean isTokenKeepAliveEnabled(org.apache.hadoop.conf.Configuration conf)
protected org.apache.hadoop.yarn.server.api.ResourceTracker getRMClient()
throws IOException
IOExceptionprotected void registerWithRM()
throws org.apache.hadoop.yarn.exceptions.YarnException,
IOException
org.apache.hadoop.yarn.exceptions.YarnExceptionIOExceptionprotected List<org.apache.hadoop.yarn.api.records.ContainerStatus> getContainerStatuses() throws IOException
IOExceptionpublic void addCompletedContainer(org.apache.hadoop.yarn.api.records.ContainerId containerId)
NodeStatusUpdateraddCompletedContainer in interface NodeStatusUpdatercontainerId - the ID of the completed container@InterfaceAudience.Private public void removeOrTrackCompletedContainersFromContext(List<org.apache.hadoop.yarn.api.records.ContainerId> containerIds) throws IOException
IOExceptionpublic void sendOutofBandHeartBeat()
NodeStatusUpdatersendOutofBandHeartBeat in interface NodeStatusUpdaterpublic boolean isContainerRecentlyStopped(org.apache.hadoop.yarn.api.records.ContainerId containerId)
NodeStatusUpdaterisContainerRecentlyStopped in interface NodeStatusUpdatercontainerId - the container IDpublic void clearFinishedContainersFromCache()
NodeStatusUpdaterclearFinishedContainersFromCache in interface NodeStatusUpdater@InterfaceAudience.Private public void removeVeryOldStoppedContainersFromCache()
public long getRMIdentifier()
NodeStatusUpdatergetRMIdentifier in interface NodeStatusUpdaterprotected void startStatusUpdater()
Copyright © 2016 Apache Software Foundation. All Rights Reserved.