You are viewing a plain text version of this content. The canonical link for it is here.
Posted to yarn-issues@hadoop.apache.org by "Hadoop QA (JIRA)" <ji...@apache.org> on 2018/11/08 11:45:00 UTC

[jira] [Commented] (YARN-8989) Move DockerCommandPlugin volume related APIs' invocation from DockerLinuxContainerRuntime#prepareContainer to #launchContainer

    [ https://issues.apache.org/jira/browse/YARN-8989?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16679647#comment-16679647 ] 

Hadoop QA commented on YARN-8989:
---------------------------------

| (/) *{color:green}+1 overall{color}* |
\\
\\
|| Vote || Subsystem || Runtime || Comment ||
| {color:blue}0{color} | {color:blue} reexec {color} | {color:blue}  0m 24s{color} | {color:blue} Docker mode activated. {color} |
|| || || || {color:brown} Prechecks {color} ||
| {color:green}+1{color} | {color:green} @author {color} | {color:green}  0m  0s{color} | {color:green} The patch does not contain any @author tags. {color} |
| {color:green}+1{color} | {color:green} test4tests {color} | {color:green}  0m  0s{color} | {color:green} The patch appears to include 1 new or modified test files. {color} |
|| || || || {color:brown} trunk Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green} 20m 26s{color} | {color:green} trunk passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  1m  2s{color} | {color:green} trunk passed {color} |
| {color:green}+1{color} | {color:green} checkstyle {color} | {color:green}  0m 27s{color} | {color:green} trunk passed {color} |
| {color:green}+1{color} | {color:green} mvnsite {color} | {color:green}  0m 39s{color} | {color:green} trunk passed {color} |
| {color:green}+1{color} | {color:green} shadedclient {color} | {color:green} 12m 56s{color} | {color:green} branch has no errors when building and testing our client artifacts. {color} |
| {color:green}+1{color} | {color:green} findbugs {color} | {color:green}  0m 55s{color} | {color:green} trunk passed {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 25s{color} | {color:green} trunk passed {color} |
|| || || || {color:brown} Patch Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  0m 36s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 57s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javac {color} | {color:green}  0m 57s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} checkstyle {color} | {color:green}  0m 21s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} mvnsite {color} | {color:green}  0m 33s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} whitespace {color} | {color:green}  0m  0s{color} | {color:green} The patch has no whitespace issues. {color} |
| {color:green}+1{color} | {color:green} shadedclient {color} | {color:green} 13m 16s{color} | {color:green} patch has no errors when building and testing our client artifacts. {color} |
| {color:green}+1{color} | {color:green} findbugs {color} | {color:green}  1m  1s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 23s{color} | {color:green} the patch passed {color} |
|| || || || {color:brown} Other Tests {color} ||
| {color:green}+1{color} | {color:green} unit {color} | {color:green} 18m 41s{color} | {color:green} hadoop-yarn-server-nodemanager in the patch passed. {color} |
| {color:green}+1{color} | {color:green} asflicense {color} | {color:green}  0m 29s{color} | {color:green} The patch does not generate ASF License warnings. {color} |
| {color:black}{color} | {color:black} {color} | {color:black} 73m 34s{color} | {color:black} {color} |
\\
\\
|| Subsystem || Report/Notes ||
| Docker | Client=17.05.0-ce Server=17.05.0-ce Image:yetus/hadoop:8f97d6f |
| JIRA Issue | YARN-8989 |
| JIRA Patch URL | https://issues.apache.org/jira/secure/attachment/12947391/YARN-8989-trunk-001.patch |
| Optional Tests |  dupname  asflicense  compile  javac  javadoc  mvninstall  mvnsite  unit  shadedclient  findbugs  checkstyle  |
| uname | Linux e61eb4a13850 3.13.0-144-generic #193-Ubuntu SMP Thu Mar 15 17:03:53 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux |
| Build tool | maven |
| Personality | /testptch/patchprocess/precommit/personality/provided.sh |
| git revision | trunk / e1bbf7d |
| maven | version: Apache Maven 3.3.9 |
| Default Java | 1.8.0_181 |
| findbugs | v3.1.0-RC1 |
|  Test Results | https://builds.apache.org/job/PreCommit-YARN-Build/22464/testReport/ |
| Max. process+thread count | 306 (vs. ulimit of 10000) |
| modules | C: hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager U: hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager |
| Console output | https://builds.apache.org/job/PreCommit-YARN-Build/22464/console |
| Powered by | Apache Yetus 0.8.0   http://yetus.apache.org |


This message was automatically generated.



> Move DockerCommandPlugin volume related APIs' invocation from DockerLinuxContainerRuntime#prepareContainer to #launchContainer
> ------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: YARN-8989
>                 URL: https://issues.apache.org/jira/browse/YARN-8989
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>            Reporter: Zhankun Tang
>            Assignee: Zhankun Tang
>            Priority: Major
>         Attachments: YARN-8989-trunk-001.patch
>
>
> This seems required before we implement isolation in pluggable device framework for default container and Docker container with LinuxContainerExecutor.
> To find a place for plugin "onDevicesAllocated" in current operation flow when running a container with LCE.
> {code:java}
> ContainerLaunch#call() ->
>     1.ContainerLaunch#prepareContainer() - >
>           LCE#prepareContainer ->
>                  DelegatingLinuxContainerRuntime#prepareContainer ->
>                       DockerLinuxContainerRuntime#prepareContainer ->
>                             DockerCommandPlugin#getCreateDockerVolumeCommand ->
>                             onDeviceAllocated(null,docker); create volume? 
>  
>      2.ContainerLaunch#launchContainer
>            LCE#launchContainer() ->
>                 resourceHandlerChain#preStart() ->
>                       DeviceResourceHandlerImpl#preStart() ->
>                              onDeviceAllocated(alloc,docker)
> allocate device and do isolation for default container with cgroup
> {code}
>  
> What I want to do here is to move the DockerCommandPlugin APIs invocation from DockerLinuxContainerRuntime#prepareContainer to #launchContainer. This won't bring any incompatibility and can benefit the pluggable device framework's interaction with the device plugin.
> The "DeviceRuntimeSpec onDevicesAllocated(Set<Device>allocation, yarnRuntime)" implemented by device plugin is to let the plugin do some preparation and return a spec on how to run the container with the allocated device. We designed a VolumeClaim field in DeviceRuntimeSpec object for the plugin to declare what volume they need to create.
> In current code flow, call this "onDevicesAllocated" in the DockerCommandPlugin's methods seems weird and can only pass a null value as allocation. This will complex the vendor device plugin implementation to handle a null value.
> Once we move the DockerCommandPlugin API invocation, it will like this:
> {code:java}
> ContainerLaunch#call() ->
>      ContainerLaunch#launchContainer
>            LCE#launchContainer() ->
>                 resourceHandlerChain#preStart() ->
>                       DeviceResourceHandlerImpl#preStart() ->
>                              onDeviceAllocated(alloc,docker)
> allocate device and do isolation for default container with cgroup
>                 DelegatingLinuxContainerRuntime#launchContaienr ->
>                     DockerLinuxContainerRuntime#launchContainer->
>                        DockerCommandPlugin#getCreateDockerVolumeCommand ->
> get allocation;onDeviceAllocated(alloc,docker);create volume{code}
> After changes, the flow is more smooth and also simplify the plugin implementation for "onDevicesAllocated"



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

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: yarn-issues-help@hadoop.apache.org