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

Jian He commented on YARN-5609:
-------------------------------

- I think this will cause the resources to be re-requested on restart. Even 
though the effect might still be the same, because the resources are already 
localized and the requests will be ignored,  but I think we can still try to 
avoid sending these unnecessary events in case the resource set is large ?
{code}
        // This is a Restart...
        return new ReInitializationContext(
            container.launchContext, container.resourceSet, null, null);
{code}
Also, suppose this is a restart after upgrade, then the old contexts are wiped 
out by this call, and user won't be able to rollback, after the restart.
- Can we add some comments about what ReInitializationContext#newResourceSet 
contains, on upgrade, it contains pendingResources only, while on rollback it 
contains full copy of original resources.

- while looking at previous code: is it possible for this call to return null ? 
If it's possible , then later code will throw NPE.
{code}
    private ReInitializationContext createContextForRollback() {
      if (oldLaunchContext == null) {
        return null;
      } else {
{code}

> Expose upgrade and restart API in ContainerManagementProtocol
> -------------------------------------------------------------
>
>                 Key: YARN-5609
>                 URL: https://issues.apache.org/jira/browse/YARN-5609
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>            Reporter: Arun Suresh
>            Assignee: Arun Suresh
>         Attachments: YARN-5609.001.patch, YARN-5609.002.patch, 
> YARN-5609.003.patch
>
>
> YARN-5620 and YARN-5637 allows an AM to explicitly *upgrade* a container with 
> a new launch context and subsequently *rollback* / *commit* the change on the 
> Container. This can also be used to simply *restart* the Container as well. 
> This JIRA proposes to extend the ContainerManagementProtocol with the 
> following API:
> * *upgradeContainer*
> * *rollbackLastUpgrade*
> * *commitLastUpgrade*
> * *restartContainer*



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

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org

Reply via email to