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

Craig Condit edited comment on YARN-9560 at 6/12/19 6:17 PM:
-------------------------------------------------------------

{quote}In the short term I would like to use as many of the docker configs as 
possible. Then if we need to make a distinction between runc and docker then we 
can define them each separately at the leaf runtimes (runc, docker) and remove 
them from OCIContainerRuntime. I'd rather not have duplicates of every configs, 
one for runc and one for docker. I'd be fine with creating OCI configs that 
support both docker and runc, but we would also need to support the current 
docker configs to make sure that we don't break compatibility.
{quote}
Perhaps we could have the OCI interface class expose a getEnvConfigPrefix() 
method, which for now would returnĀ  "DOCKER", but in the RunC runtime could 
return "RUNC"? The base class could use this to dynamically namespace the 
configs which are supported by both. I think it will be very confusing to users 
to have DOCKER_* props refer to the runc runtime. Doing this preserves 
backwards compatibility without forcing duplicate logic for handling common 
properties between the different implementations. There is some mechanical work 
in the base class to remove DOCKER and add getEnvConfigPrefix() instead, but 
this seems simple enough.


was (Author: ccondit):
Perhaps we could have the OCI interface class expose a getEnvConfigPrefix() 
method, which for now would returnĀ  "DOCKER", but in the RunC runtime could 
return "RUNC"? The base class could use this to dynamically namespace the 
configs which are supported by both. I think it will be very confusing to users 
to have DOCKER_* props refer to the runc runtime.

> Restructure DockerLinuxContainerRuntime to extend a new OCIContainerRuntime
> ---------------------------------------------------------------------------
>
>                 Key: YARN-9560
>                 URL: https://issues.apache.org/jira/browse/YARN-9560
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>            Reporter: Eric Badger
>            Assignee: Eric Badger
>            Priority: Major
>              Labels: Docker
>         Attachments: YARN-9560.001.patch, YARN-9560.002.patch, 
> YARN-9560.003.patch, YARN-9560.004.patch, YARN-9560.005.patch, 
> YARN-9560.006.patch
>
>
> Since the new OCI/squashFS/runc runtime will be using a lot of the same code 
> as DockerLinuxContainerRuntime, it would be good to move a bunch of the 
> DockerLinuxContainerRuntime code up a level to an abstract class that both of 
> the runtimes can extend. 
> The new structure will look like:
> {noformat}
> OCIContainerRuntime (abstract class)
>   - DockerLinuxContainerRuntime
>   - FSImageContainerRuntime (name negotiable)
> {noformat}
> This JIRA should only change the structure of the code, not the actual 
> semantics



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

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

Reply via email to