hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sandy Ryza (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-1447) Common PB types define for container resource change
Date Tue, 03 Dec 2013 09:34:36 GMT

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

Sandy Ryza commented on YARN-1447:

Thanks Wangda.  The proto definitions look good to me now.  Just some stylistic comments on
the patch:

+abstract public class ContainerResourceDecrease {
"public" should come before "abstract".  Also applies to a couple other places.

+ * Used by AM to ask NM reduce size of a specified container
Better to spell it out - Used by application masters to as NodeManagers to reduce the size
of a specified container.  The same applies to a few different places.

+      if ((getContainerId() == null) ^ (ctx.getContainerId() == null)) {
It's more traditional to use "||" which can short-circuit, than "^".  Applies to a couple
other places as well.

+    ContainerResourceIncreaseRequestProto proto = ((ContainerResourceIncreaseRequestPBImpl)context).getProto();
+    ContainerResourceIncreaseRequest contextRecover = new ContainerResourceIncreaseRequestPBImpl(proto);
Way over 80 characters.

> Common PB types define for container resource change
> ----------------------------------------------------
>                 Key: YARN-1447
>                 URL: https://issues.apache.org/jira/browse/YARN-1447
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: api
>    Affects Versions: 2.2.0
>            Reporter: Wangda Tan
>            Assignee: Wangda Tan
>         Attachments: yarn-1447.1.patch, yarn-1447.2.patch
> As described in YARN-1197, we need add some common PB types for container resource change,
like ResourceChangeContext, etc. These types will be both used by RM/NM protocols

This message was sent by Atlassian JIRA

View raw message