Bikas Saha commented on YARN-1509:

A change container request (maybe not supported now) can be increase cpu + 
decrease memory. Hence a built in concept of increase and decrease in the API 
is something I am wary off.
So how about
{code} public abstract void onContainersResourceChanged(
        Map<Container,Container> oldToNewContainers); 
public abstract void onContainersResourceChanged(
        List<UpdatedContainerInfo>  updatedContainerInfo);{code}

Would there be a case (maybe not currently) when a change container request can 
fail on the RM? Should the callback allow notifying about a failure to change 
the container?
What is the RM notifies AMRMClient about a container completed. That container 
happens to have a pending change request? What should happen in this case? 
Should the AMRM client clear that pending request? Should it also notify the 
user that pending container change request has failed or just rely on 
onContainerCompleted() to let the AM get that information.

I would be wary of overloading cancel with a second container change request. 
To be clear, here we are discussing user facing semantics and API. Having clear 
semantics is important vs implicit or overloaded behavior. E.g. are there cases 
where an increase followed by a decrease request is a valid scenario and how 
would that be different compare to an increase followed by a cancel. Should the 
RM do different things for increase followed by cancel vs increase followed by 

AM restart does not need any handling since the AM is going to start from a 
clean slate. Sorry, my bad.

I missed the handling of the RM restart case. Is there an existing test for 
that code path that could be augmented to make sure that the new changes are 

> Make AMRMClient support send increase container request and get 
> increased/decreased containers
> ----------------------------------------------------------------------------------------------
>                 Key: YARN-1509
>                 URL: https://issues.apache.org/jira/browse/YARN-1509
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: resourcemanager
>            Reporter: Wangda Tan (No longer used)
>            Assignee: MENG DING
>         Attachments: YARN-1509.1.patch, YARN-1509.2.patch, YARN-1509.3.patch, 
> YARN-1509.4.patch, YARN-1509.5.patch
> As described in YARN-1197, we need add API in AMRMClient to support
> 1) Add increase request
> 2) Can get successfully increased/decreased containers from RM

This message was sent by Atlassian JIRA

Reply via email to