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

Sandy Ryza commented on YARN-588:
---------------------------------

Thanks for the patch, Niranjan!  Since I filed this JIRA, a newInstance method 
was added to Resource itself, so I think it would be preferable to use that one 
over the one in BuilderUtils, which hopefully will be phased out.

Also, would it be possible to remove the single-argument 
Resources#createResource as well?  It will require explicitly putting 0 or 1 in 
the places it's used, but I think this is probably advantageous for preventing 
unexpected behavior as YARN becomes more multi-resource centric. 
                
> Two identical utility methods in different classes to build Resource
> --------------------------------------------------------------------
>
>                 Key: YARN-588
>                 URL: https://issues.apache.org/jira/browse/YARN-588
>             Project: Hadoop YARN
>          Issue Type: Improvement
>          Components: api
>    Affects Versions: 2.0.3-alpha
>            Reporter: Sandy Ryza
>            Assignee: Niranjan Singh
>            Priority: Minor
>              Labels: newbie
>         Attachments: YARN-588.patch
>
>
> Both Resources and BuilderUtils have a method that takes the same arguments 
> to build a Resource object.  The code doesn't need both of these methods.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to