hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eric Payne (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-4225) Add preemption status to yarn queue -status for capacity scheduler
Date Mon, 23 Nov 2015 18:02:10 GMT

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

Eric Payne commented on YARN-4225:
----------------------------------

bq. someone might call has when they should be calling get. Maybe a name like "isPreemptionDisabledValid"
or something would be more clear
In order to remove the need for two methods, another alternative would be to have {{QueueInfoPBImpl#getPreemptionDisabled}}
return a {{Boolean}} rather than a native type, and then have it return null if it internally
determines that the field is not there.

 So, in {{QueueCLI#printQueueInfo}}, the code would look something like this:
{code}
    Boolean preemptStatus = queueInfo.getPreemptionDisabled();
    if (preemptStatus != null) {
      writer.print("\tPreemption : ");
      writer.println(preemptStatus ? "disabled" : "enabled");
    }
{code}


In General, what is the Hadoop policy when a newer client talks to an older server and the
protobuf output is different than expected. Should we expose some form of the {{has}} method,
or should we overload the {{get}} method as I described here?

 I would appreciate any additional feedback from the community in general ([~vinodkv], do
you have any thoughts?)

> Add preemption status to yarn queue -status for capacity scheduler
> ------------------------------------------------------------------
>
>                 Key: YARN-4225
>                 URL: https://issues.apache.org/jira/browse/YARN-4225
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: capacity scheduler, yarn
>    Affects Versions: 2.7.1
>            Reporter: Eric Payne
>            Assignee: Eric Payne
>            Priority: Minor
>         Attachments: YARN-4225.001.patch, YARN-4225.002.patch
>
>




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message