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

Sunil G edited comment on YARN-5588 at 2/3/17 1:23 PM:
-------------------------------------------------------

Thanks [~vvasudev] for the patch.

Few comments in general:
1. ProfileCapability

1.1) Instead of having a variable named {{Resource none}}, we could use 
Resource.NONE itself
1.2) {{tmp}}  --> {{profileName}}

2. ApplicationMaster

2.1) {{containerResourceProfile=""}}, could we define a static variable as 
{{EMPTY_PROFILE}} and could use every where.
2.2) In {[createProfileCapability}}, need to use {{containerMemory}} in below 
code instead of {{containerVirtualCores}}
{code}
containerMemory = containerMemory == -1 ? DEFAULT_CONTAINER_MEMORY :
                  containerVirtualCores;
{code}
2.3) May be {{tmp}} could be renamed to {{profileName}}

3. Client

3.1) {{for (String profile : appProfiles}}, could we rename profile -> 
appProfile to avoid naming confusion.
3.2) In {{setAMResourceCapability}}, can amMemory from 
{{profiles.get(tmp).getMemorySize()}} could be less than {{memory}} and cause 
Xmx issue.




was (Author: sunilg):
Thanks [~vvasudev] for the patch.

Few comments in general:
1. ProfileCapability

1.1) Instead of having a variable named {{Resource none}}, we could use 
Resource.NONE itself
1.2) {{tmp}}  --> {{profileName}}

2. ApplicationMaster

2.1) {{containerResourceProfile=""}}, could we define a static variable as 
{{EMPTY_PROFILE}} and could use every where.
2.2) In {[createProfileCapability }}, need to use {{containerMemory}} in below 
code instead of {{containerVirtualCores}}
{code}
containerMemory = containerMemory == -1 ? DEFAULT_CONTAINER_MEMORY :
                  containerVirtualCores;
{code}
2.3) May be {{tmp}} could be renamed to {{profileName}}

3. Client

3.1) {{for (String profile : appProfiles) }}, could we rename profile -> 
appProfile to avoid naming confusion.
3.2) In {{setAMResourceCapability}}, can amMemory from 
{{profiles.get(tmp).getMemorySize()}} could be less than {{memory}} and cause 
Xmx issue.



> Add support for resource profiles in distributed shell
> ------------------------------------------------------
>
>                 Key: YARN-5588
>                 URL: https://issues.apache.org/jira/browse/YARN-5588
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: nodemanager, resourcemanager
>            Reporter: Varun Vasudev
>            Assignee: Varun Vasudev
>         Attachments: YARN-5588-YARN-3926.001.patch, 
> YARN-5588-YARN-3926.002.patch, YARN-5588-YARN-3926.003.patch
>
>




--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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

Reply via email to