[
https://issues.apache.org/jira/browse/YARN-7034?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16166677#comment-16166677
]
Shane Kumpf commented on YARN-7034:
-----------------------------------
Thanks for the patch [[email protected]]! Overall the patch looks
good to me when testing against trunk. I can't come up with a use case for
container-executor needing these environment variables.
Couple of minor nits regarding the patch.
1) With the removal of the getEnvironment calls, the line length is greatly
reduced, so I think the new line in between args isn't necessary anymore. This
occurs in a few places.
{code}
- launchOp, null, container.getLaunchContext().getEnvironment(),
+ launchOp, null, null,
false, false);
{code}
2) The word privileged is misspelled for mockPriviligedExec
{code}
+ mockPriviligedExec = Mockito.mock(PrivilegedOperationExecutor.class);
{code}
3) In testContainerLaunch the FROM_CLIENT environment variable is being set,
but I don't think the test uses it. Can this be removed?
{code}
-
+ env.put("FROM_CLIENT", "1");
+
{code}
4) testContainerLaunchEnvironment has a couple of unused variables.
{code}
+ String cmd = String.valueOf(
+ PrivilegedOperation.RunAsUserCommand.LAUNCH_CONTAINER.getValue());
-snip-
+ int ret =
{code}
> DefaultLinuxContainerRuntime and DockerLinuxContainerRuntime sends client
> environment variables to container-executor
> ---------------------------------------------------------------------------------------------------------------------
>
> Key: YARN-7034
> URL: https://issues.apache.org/jira/browse/YARN-7034
> Project: Hadoop YARN
> Issue Type: Bug
> Components: nodemanager
> Reporter: Miklos Szegedi
> Assignee: Miklos Szegedi
> Priority: Critical
> Attachments: YARN-7034.000.patch, YARN-7034.001.patch,
> YARN-7034.002.patch, YARN-7034.003.patch, YARN-7034.branch-2.000.patch,
> YARN-7034.branch-2.8.000.patch
>
>
> This behavior is unnecessary since there is nothing that is used from the
> environment right now. One option is to whitelist these variables before
> passing them. Are there any known use cases for this to justify?
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]