Jian He commented on YARN-2694:

- check “||” too? “more than two node labels”, two is also invalid. call it 
multiple node labels. 
// Don't support specifying >= 2 node labels in a node label expression now
    if (null != exp && exp.contains("&&")) {
      throw new InvalidContainerRequestException(
          "Cannot specify more than two node labels"
              + " in a single node label expression");

- for above, also throw exception if node label is specified for a non-any 
-  should not use IOException? {{throw new IOException(String.format("%d labels 
specified on host=%s”}}, we may use the Precondition.check
- may be say: Note that we currently do not support specifying multiple labels 
on a single host?
please note we temporarily disable specify"
            + " more than one label on each host for now.
- this should be after request sanity validation 
      // set label expression for Resource Requests if resourceName=ANY 
      ApplicationSubmissionContext asc = app.getApplicationSubmissionContext();
      for (ResourceRequest req : ask) {
        if (null == req.getNodeLabelExpression()
            && ResourceRequest.ANY.equals(req.getResourceName())) {

> Ensure only single node labels specified in resource request / host, and node 
> label expression only specified when resourceName=ANY
> -----------------------------------------------------------------------------------------------------------------------------------
>                 Key: YARN-2694
>                 URL: https://issues.apache.org/jira/browse/YARN-2694
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: capacityscheduler, resourcemanager
>            Reporter: Wangda Tan
>            Assignee: Wangda Tan
>         Attachments: YARN-2694-20141020-1.patch, YARN-2694-20141021-1.patch, 
> YARN-2694-20141023-1.patch, YARN-2694-20141023-2.patch, 
> YARN-2694-20141101-1.patch, YARN-2694-20141101-2.patch, 
> YARN-2694-20150121-1.patch, YARN-2694-20150122-1.patch, 
> YARN-2694-20150202-1.patch, YARN-2694-20150203-1.patch
> Currently, node label expression supporting in capacity scheduler is partial 
> completed. Now node label expression specified in Resource Request will only 
> respected when it specified at ANY level. And a ResourceRequest/host with 
> multiple node labels will make user limit, etc. computation becomes more 
> tricky.
> Now we need temporarily disable them, changes include,
> - AMRMClient
> - ApplicationMasterService
> - RMAdminCLI
> - CommonNodeLabelsManager

This message was sent by Atlassian JIRA

Reply via email to