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 |
getContainerLaunchTime()
The timestamp when the container is allowed to be launched.
|
<T> T |
getContainerRuntimeData(Class<T> runtimeClass) |
long |
getContainerStartTime()
The timestamp when the container start request is received.
|
ContainerState |
getContainerState() |
org.apache.hadoop.yarn.security.ContainerTokenIdentifier |
getContainerTokenIdentifier() |
org.apache.hadoop.security.Credentials |
getCredentials() |
String |
getCsiVolumesRootDir() |
org.apache.hadoop.yarn.api.records.ContainerState |
getCurrentState() |
org.apache.hadoop.yarn.api.records.ContainerLaunchContext |
getLaunchContext() |
List<org.apache.hadoop.yarn.api.records.LocalizationStatus> |
getLocalizationStatuses()
Get the localization statuses.
|
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 |
isContainerInFinalStates()
Verify container is in final states.
|
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 |
setContainerRuntimeData(Object containerRuntimeData) |
void |
setContainerTokenIdentifier(org.apache.hadoop.yarn.security.ContainerTokenIdentifier token) |
void |
setCsiVolumesRootDir(String volumesRootDir) |
void |
setExposedPorts(String ports) |
void |
setIpAndHost(String[] ipAndHost) |
void |
setIsReInitializing(boolean isReInitializing) |
void |
setLogDir(String logDir) |
void |
setWorkDir(String workDir) |
boolean |
shouldRetry(int errorCode) |
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()
ContainergetContainerStartTime in interface Containerpublic long getContainerLaunchTime()
ContainergetContainerLaunchTime 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 String getCsiVolumesRootDir()
getCsiVolumesRootDir in interface Containerpublic void setCsiVolumesRootDir(String volumesRootDir)
setCsiVolumesRootDir 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 void handle(ContainerEvent event)
handle in interface org.apache.hadoop.yarn.event.EventHandler<ContainerEvent>public String toString()
public org.apache.hadoop.yarn.api.records.Priority getPriority()
getPriority in interface Containerpublic 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 ResourceMappings getResourceMappings()
getResourceMappings in interface Containerpublic boolean isContainerInFinalStates()
ContainerisContainerInFinalStates in interface Containerpublic void setExposedPorts(String ports)
setExposedPorts in interface Containerpublic List<org.apache.hadoop.yarn.api.records.LocalizationStatus> getLocalizationStatuses()
ContainergetLocalizationStatuses in interface Containerpublic void setContainerRuntimeData(Object containerRuntimeData)
setContainerRuntimeData in interface Containerpublic <T> T getContainerRuntimeData(Class<T> runtimeClass) throws ContainerExecutionException
getContainerRuntimeData in interface ContainerContainerExecutionExceptionpublic String localizationCountersAsString()
Container$LOCALIZATION_COUNTERS. See
ApplicationConstants.Environment.LOCALIZATION_COUNTERSlocalizationCountersAsString in interface ContainerCopyright © 2008–2024 Apache Software Foundation. All rights reserved.