[ 
https://issues.apache.org/jira/browse/YARN-9074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Zhaohui Xin updated YARN-9074:
------------------------------
    Description: 
Now, when container is finished, we firstly execute "_docker rm xxx"_  to 
remove it which thread is place deletionService. see more in 
https://issues.apache.org/jira/browse/YARN-5366 

[YARN-5366|]https://issues.apache.org/jira/browse/YARN-5366] 

After, we 

 
{code:java}
@Override
public void transition(ContainerImpl container, ContainerEvent event) {

container.setIsReInitializing(false);
// Set exit code to 0 on success 
container.exitCode = 0;

// TODO: Add containerWorkDir to the deletion service.

if (DockerLinuxContainerRuntime.isDockerContainerRequested(
container.daemonConf,
container.getLaunchContext().getEnvironment())) {
removeDockerContainer(container);
}

if (clCleanupRequired) {
container.dispatcher.getEventHandler().handle(
new ContainersLauncherEvent(container,
ContainersLauncherEventType.CLEANUP_CONTAINER));
}

container.cleanup();
}
{code}

  was:
Now, when container is finished, we firstly execute "_docker rm xxx"_  to 
remove it which thread is place deletionService. see more in 

 

After, we 

 
{code:java}
@Override
public void transition(ContainerImpl container, ContainerEvent event) {

container.setIsReInitializing(false);
// Set exit code to 0 on success 
container.exitCode = 0;

// TODO: Add containerWorkDir to the deletion service.

if (DockerLinuxContainerRuntime.isDockerContainerRequested(
container.daemonConf,
container.getLaunchContext().getEnvironment())) {
removeDockerContainer(container);
}

if (clCleanupRequired) {
container.dispatcher.getEventHandler().handle(
new ContainersLauncherEvent(container,
ContainersLauncherEventType.CLEANUP_CONTAINER));
}

container.cleanup();
}
{code}


> Docker container rm command should be executed after stop
> ---------------------------------------------------------
>
>                 Key: YARN-9074
>                 URL: https://issues.apache.org/jira/browse/YARN-9074
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>            Reporter: Zhaohui Xin
>            Assignee: Zhaohui Xin
>            Priority: Major
>
> Now, when container is finished, we firstly execute "_docker rm xxx"_  to 
> remove it which thread is place deletionService. see more in 
> https://issues.apache.org/jira/browse/YARN-5366 
> [YARN-5366|]https://issues.apache.org/jira/browse/YARN-5366] 
> After, we 
>  
> {code:java}
> @Override
> public void transition(ContainerImpl container, ContainerEvent event) {
> container.setIsReInitializing(false);
> // Set exit code to 0 on success 
> container.exitCode = 0;
> // TODO: Add containerWorkDir to the deletion service.
> if (DockerLinuxContainerRuntime.isDockerContainerRequested(
> container.daemonConf,
> container.getLaunchContext().getEnvironment())) {
> removeDockerContainer(container);
> }
> if (clCleanupRequired) {
> container.dispatcher.getEventHandler().handle(
> new ContainersLauncherEvent(container,
> ContainersLauncherEventType.CLEANUP_CONTAINER));
> }
> container.cleanup();
> }
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to