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

Eric Yang commented on YARN-9560:
---------------------------------

[~Jim_Brennan] From OCIRuntime and DockerLinuxContainerRuntime perspective, 
they are static string. The config key strings do not change when used in those 
classes. They will only change when a third implementation say RuncRuntime is 
implemented and allowing DockerLinuxContainerRuntime configuration keys to work 
in RuncRuntime. Instance variables only make sense to handle the config key 
overload in RuncRuntime because config keys becomes variables base on 
additional cluster config, and not static strings. This makes it more clear to 
the developers that they need to handle config key shading in RuncRuntime with 
care, while keeping DockerLinuxContainerRuntime logic as closely to how it was 
written as possible. This helps the community to maintaining the existing code 
base with least amount of risk to configuration fragmentation into multiple 
runtimes. Disruptive retrofitting to Docker runtime requires human parser to 
figure out if code sharing is put in the right place. Without ability to 
statically define Docker configuration key in DockerLinuxContainerRuntime, 
there is a risk to have Docker config key pop up in RuncRuntime or Runc config 
pop up in Docker. This goes back to my original concern that config key 
fragmentation issue hasn't been addressed correctly in patch 11.

> 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, YARN-9560.007.patch, YARN-9560.008.patch, 
> YARN-9560.009.patch, YARN-9560.010.patch, YARN-9560.011.patch
>
>
> Since the new RuncContainerRuntime 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
>   - RuncContainerRuntime
> {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