public class ContainerImpl extends Object implements Container
| Constructor and Description |
|---|
ContainerImpl(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.yarn.event.Dispatcher dispatcher,
org.apache.hadoop.yarn.api.records.ContainerLaunchContext launchContext,
org.apache.hadoop.security.Credentials creds,
NodeManagerMetrics metrics,
org.apache.hadoop.yarn.security.ContainerTokenIdentifier containerTokenIdentifier,
Context context) |
ContainerImpl(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.yarn.event.Dispatcher dispatcher,
org.apache.hadoop.yarn.api.records.ContainerLaunchContext launchContext,
org.apache.hadoop.security.Credentials creds,
NodeManagerMetrics metrics,
org.apache.hadoop.yarn.security.ContainerTokenIdentifier containerTokenIdentifier,
Context context,
long startTs) |
ContainerImpl(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.yarn.event.Dispatcher dispatcher,
org.apache.hadoop.yarn.api.records.ContainerLaunchContext launchContext,
org.apache.hadoop.security.Credentials creds,
NodeManagerMetrics metrics,
org.apache.hadoop.yarn.security.ContainerTokenIdentifier containerTokenIdentifier,
Context context,
NMStateStoreService.RecoveredContainerState rcs) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canRollback() |
void |
cleanup() |
org.apache.hadoop.yarn.api.records.ContainerStatus |
cloneAndGetContainerStatus() |
void |
commitUpgrade() |
org.apache.hadoop.yarn.api.records.ContainerId |
getContainerId() |
long |
getContainerStartTime() |
ContainerState |
getContainerState() |
org.apache.hadoop.yarn.security.ContainerTokenIdentifier |
getContainerTokenIdentifier() |
org.apache.hadoop.security.Credentials |
getCredentials() |
org.apache.hadoop.yarn.api.records.ContainerState |
getCurrentState() |
org.apache.hadoop.yarn.api.records.ContainerLaunchContext |
getLaunchContext() |
Map<org.apache.hadoop.fs.Path,List<String>> |
getLocalizedResources() |
String |
getLogDir() |
org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus |
getNMContainerStatus() |
NMTimelinePublisher |
getNMTimelinePublisher() |
org.apache.hadoop.yarn.api.records.Priority |
getPriority() |
org.apache.hadoop.yarn.api.records.Resource |
getResource() |
ResourceMappings |
getResourceMappings()
Get assigned resource mappings to the container.
|
ResourceSet |
getResourceSet() |
String |
getUser() |
String |
getWorkDir() |
void |
handle(ContainerEvent event) |
boolean |
isMarkedForKilling() |
boolean |
isRecovering() |
boolean |
isReInitializing() |
boolean |
isRetryContextSet() |
boolean |
isRunning() |
String |
localizationCountersAsString()
Vector of localization counters to be passed from NM to application
container via environment variable
$LOCALIZATION_COUNTERS. |
void |
sendKillEvent(int exitStatus,
String description) |
void |
sendLaunchEvent() |
void |
sendPauseEvent(String description) |
void |
setContainerTokenIdentifier(org.apache.hadoop.yarn.security.ContainerTokenIdentifier token) |
void |
setIpAndHost(String[] ipAndHost) |
void |
setIsReInitializing(boolean isReInitializing) |
void |
setLogDir(String logDir) |
void |
setWorkDir(String workDir) |
boolean |
shouldRetry(int errorCode) |
static boolean |
shouldRetry(int errorCode,
org.apache.hadoop.yarn.api.records.ContainerRetryContext retryContext,
int remainingRetryAttempts) |
String |
toString() |
public ContainerImpl(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.yarn.event.Dispatcher dispatcher,
org.apache.hadoop.yarn.api.records.ContainerLaunchContext launchContext,
org.apache.hadoop.security.Credentials creds,
NodeManagerMetrics metrics,
org.apache.hadoop.yarn.security.ContainerTokenIdentifier containerTokenIdentifier,
Context context)
public ContainerImpl(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.yarn.event.Dispatcher dispatcher,
org.apache.hadoop.yarn.api.records.ContainerLaunchContext launchContext,
org.apache.hadoop.security.Credentials creds,
NodeManagerMetrics metrics,
org.apache.hadoop.yarn.security.ContainerTokenIdentifier containerTokenIdentifier,
Context context,
long startTs)
public ContainerImpl(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.yarn.event.Dispatcher dispatcher,
org.apache.hadoop.yarn.api.records.ContainerLaunchContext launchContext,
org.apache.hadoop.security.Credentials creds,
NodeManagerMetrics metrics,
org.apache.hadoop.yarn.security.ContainerTokenIdentifier containerTokenIdentifier,
Context context,
NMStateStoreService.RecoveredContainerState rcs)
public org.apache.hadoop.yarn.api.records.ContainerState getCurrentState()
public NMTimelinePublisher getNMTimelinePublisher()
public Map<org.apache.hadoop.fs.Path,List<String>> getLocalizedResources()
getLocalizedResources in interface Containerpublic org.apache.hadoop.security.Credentials getCredentials()
getCredentials in interface Containerpublic ContainerState getContainerState()
getContainerState in interface Containerpublic org.apache.hadoop.yarn.api.records.ContainerLaunchContext getLaunchContext()
getLaunchContext in interface Containerpublic org.apache.hadoop.yarn.api.records.ContainerStatus cloneAndGetContainerStatus()
cloneAndGetContainerStatus in interface Containerpublic org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus getNMContainerStatus()
getNMContainerStatus in interface Containerpublic org.apache.hadoop.yarn.api.records.ContainerId getContainerId()
getContainerId in interface Containerpublic long getContainerStartTime()
getContainerStartTime in interface Containerpublic org.apache.hadoop.yarn.api.records.Resource getResource()
getResource in interface Containerpublic org.apache.hadoop.yarn.security.ContainerTokenIdentifier getContainerTokenIdentifier()
getContainerTokenIdentifier in interface Containerpublic void setContainerTokenIdentifier(org.apache.hadoop.yarn.security.ContainerTokenIdentifier token)
setContainerTokenIdentifier in interface Containerpublic String getWorkDir()
getWorkDir in interface Containerpublic void setWorkDir(String workDir)
setWorkDir in interface Containerpublic void setIpAndHost(String[] ipAndHost)
setIpAndHost in interface Containerpublic ResourceSet getResourceSet()
getResourceSet in interface Containerpublic void sendLaunchEvent()
sendLaunchEvent in interface Containerpublic void sendKillEvent(int exitStatus,
String description)
sendKillEvent in interface Containerpublic void sendPauseEvent(String description)
sendPauseEvent in interface Containerpublic void cleanup()
public boolean isRetryContextSet()
isRetryContextSet in interface Containerpublic boolean shouldRetry(int errorCode)
shouldRetry in interface Containerpublic static boolean shouldRetry(int errorCode,
org.apache.hadoop.yarn.api.records.ContainerRetryContext retryContext,
int remainingRetryAttempts)
public void handle(ContainerEvent event)
handle in interface org.apache.hadoop.yarn.event.EventHandler<ContainerEvent>public String toString()
public void setIsReInitializing(boolean isReInitializing)
setIsReInitializing in interface Containerpublic boolean isReInitializing()
isReInitializing in interface Containerpublic boolean isMarkedForKilling()
isMarkedForKilling in interface Containerpublic boolean canRollback()
canRollback in interface Containerpublic void commitUpgrade()
commitUpgrade in interface Containerpublic boolean isRecovering()
isRecovering in interface Containerpublic org.apache.hadoop.yarn.api.records.Priority getPriority()
getPriority in interface Containerpublic ResourceMappings getResourceMappings()
getResourceMappings in interface Containerpublic String localizationCountersAsString()
Container$LOCALIZATION_COUNTERS. See
ApplicationConstants.Environment.LOCALIZATION_COUNTERSlocalizationCountersAsString in interface ContainerCopyright © 2022 Apache Software Foundation. All rights reserved.