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

Bikas Saha commented on YARN-521:
---------------------------------

The following comment from YARN-392 shows some of the potential invalid 
requests that we must check for. The comments in response to this implied that 
we agreed that we should make sure checks are performed in the AMRMClient to 
prevent such invalid cases. I dont see any checks being performed in the patch 
that catch invalid scenarios. Its essential that we have them here or else the 
app can end up in a situation in which some of its request may not be satisfied 
correctly.
https://issues.apache.org/jira/browse/YARN-392?focusedCommentId=13653374&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13653374
Adding the scenarios inline for clarity.

"How about this case. Time T1 I make request at priority P1 for specific node 
N1 in rack R1. So now R1 & * have relaxLocality set to false to prevent 
allocation at rack/* for that priority. Now at time T2, if I make a request at 
priority P1 for specific rack R1. That would require relaxLocality flag to be 
false only on *. That is incompatible with the existing flags set. Next case, 
at T1 I make P1 request for specific node N1 in rack R1. At T2 I make P1 
request for non-specific node N2 in the same rack R1. Now the relaxLocality 
flag on rack R1 is incompatible for both requests."


I have a feeling that getMatchingRequests() needs to account for the new 
locality preference.

btw. why are are changing the comments? The older version was more concise and 
clear IMO.
{code}
    * @param priority
-   *    The priority at which to request the containers. Higher priorities have
-   *    lower numerical values.
+   *    The priority at which to request the containers. Containers requested
+   *    at priorities closer to 0 will always be assigned first when all
+   *    other scheduling constraints are equal.
{code}
                
> Augment AM - RM client module to be able to request containers only at 
> specific locations
> -----------------------------------------------------------------------------------------
>
>                 Key: YARN-521
>                 URL: https://issues.apache.org/jira/browse/YARN-521
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: api
>    Affects Versions: 2.0.3-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-521.patch
>
>
> When YARN-392 and YARN-398 are completed, it would be good for AMRMClient to 
> offer an easy way to access their functionality

--
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