You are viewing a plain text version of this content. The canonical link for it is here.
Posted to yarn-issues@hadoop.apache.org by "Sandy Ryza (JIRA)" <ji...@apache.org> on 2012/10/18 22:36:03 UTC

[jira] [Created] (YARN-170) NodeManager stop() gets called twice on shutdown

Sandy Ryza created YARN-170:
-------------------------------

             Summary: NodeManager stop() gets called twice on shutdown
                 Key: YARN-170
                 URL: https://issues.apache.org/jira/browse/YARN-170
             Project: Hadoop YARN
          Issue Type: Bug
          Components: nodemanager
    Affects Versions: 2.0.2-alpha
            Reporter: Sandy Ryza
            Assignee: Sandy Ryza


The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.

The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager

This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Sandy Ryza (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13507056#comment-13507056 ] 

Sandy Ryza commented on YARN-170:
---------------------------------

I put in the license headers, changed the reboot() method to private, and added a test that makes sure the NodeManager's stop method only gets called once.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170-1.patch, YARN-170-2.patch, YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Updated] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Sandy Ryza (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sandy Ryza updated YARN-170:
----------------------------

    Attachment: YARN-170.patch
    
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Sandy Ryza (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13480105#comment-13480105 ] 

Sandy Ryza commented on YARN-170:
---------------------------------

I'm new to the codebase, so let me know if I'm misunderstanding the way things work, but the way I was looking at it was:

The NodeStatusUpdater signalling by stopping itself and expecting the NodeManager to notice seems like an unnecessary overloading of the NodeStatusUpdater shutdown, requiring the extra coordination of the NodeStatusUpdater's hasToReboot variable.  In a hierarchy of services, shouldn't the parents stop first, and be responsible for stopping their descendants?  The way it's implemented now violates the hierarchy as well, just in a less direct way that tangles the already complicated shutdown procedure.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Updated] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Sandy Ryza (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sandy Ryza updated YARN-170:
----------------------------

    Attachment: YARN-170-2.patch
    
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170-1.patch, YARN-170-2.patch, YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13504780#comment-13504780 ] 

Hadoop QA commented on YARN-170:
--------------------------------

{color:red}-1 overall{color}.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12550336/YARN-170.patch
  against trunk revision .

    {color:red}-1 patch{color}.  The patch command could not apply the patch.

Console output: https://builds.apache.org/job/PreCommit-YARN-Build/163//console

This message is automatically generated.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Vinod Kumar Vavilapalli (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13479590#comment-13479590 ] 

Vinod Kumar Vavilapalli commented on YARN-170:
----------------------------------------------

bq. This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.
NodeStatusUpdater shouldn't call NodeManager stop directly, it violates the composition hierarchy. Instead NM's stop() should simply be re-entrant.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Sandy Ryza (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13481659#comment-13481659 ] 

Sandy Ryza commented on YARN-170:
---------------------------------

Ok, I understand better now.  I wrote it so that the NodeStatusUpdater signals to the NodeManager with an event. 
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13505649#comment-13505649 ] 

Hadoop QA commented on YARN-170:
--------------------------------

{color:red}-1 overall{color}.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12555066/YARN-170-1.patch
  against trunk revision .

    {color:green}+1 @author{color}.  The patch does not contain any @author tags.

    {color:red}-1 tests included{color}.  The patch doesn't appear to include any new or modified tests.
                        Please justify why no new tests are needed for this patch.
                        Also please list what manual steps were performed to verify this patch.

    {color:green}+1 javac{color}.  The applied patch does not increase the total number of javac compiler warnings.

    {color:green}+1 javadoc{color}.  The javadoc tool did not generate any warning messages.

    {color:green}+1 eclipse:eclipse{color}.  The patch built with eclipse:eclipse.

    {color:green}+1 findbugs{color}.  The patch does not introduce any new Findbugs (version 1.3.9) warnings.

    {color:green}+1 release audit{color}.  The applied patch does not increase the total number of release audit warnings.

    {color:green}+1 core tests{color}.  The patch passed unit tests in hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager.

    {color:green}+1 contrib tests{color}.  The patch passed contrib unit tests.

Test results: https://builds.apache.org/job/PreCommit-YARN-Build/178//testReport/
Console output: https://builds.apache.org/job/PreCommit-YARN-Build/178//console

This message is automatically generated.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170-1.patch, YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Vinod Kumar Vavilapalli (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13480359#comment-13480359 ] 

Vinod Kumar Vavilapalli commented on YARN-170:
----------------------------------------------

You are mostly right. The NodeStatusUpdater is the component responsible for communicating with RM constantly. In some cases, like a network parition, or when RM reboots, RM asks the NMs to shutdown or reboot. In this case, NodeStatusUpdater needs to inform its parent i.e. NodeManager to shutdown. To avoid stopping it directly, it should ideally send a signal to the NM. Today we achieve it via stateChanged event, NodeManager listens on state change events and shuts itself down. The shortest path to fixing the issue you mentioned is by making stop re-entrant.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Updated] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Sandy Ryza (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sandy Ryza updated YARN-170:
----------------------------

    Attachment: YARN-170-1.patch
    
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170-1.patch, YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13505381#comment-13505381 ] 

Hadoop QA commented on YARN-170:
--------------------------------

{color:red}-1 overall{color}.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12555066/YARN-170-1.patch
  against trunk revision .

    {color:green}+1 @author{color}.  The patch does not contain any @author tags.

    {color:red}-1 tests included{color}.  The patch doesn't appear to include any new or modified tests.
                        Please justify why no new tests are needed for this patch.
                        Also please list what manual steps were performed to verify this patch.

    {color:green}+1 javac{color}.  The applied patch does not increase the total number of javac compiler warnings.

    {color:green}+1 javadoc{color}.  The javadoc tool did not generate any warning messages.

    {color:green}+1 eclipse:eclipse{color}.  The patch built with eclipse:eclipse.

    {color:green}+1 findbugs{color}.  The patch does not introduce any new Findbugs (version 1.3.9) warnings.

    {color:green}+1 release audit{color}.  The applied patch does not increase the total number of release audit warnings.

    {color:green}+1 core tests{color}.  The patch passed unit tests in hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager.

    {color:green}+1 contrib tests{color}.  The patch passed contrib unit tests.

Test results: https://builds.apache.org/job/PreCommit-YARN-Build/167//testReport/
Console output: https://builds.apache.org/job/PreCommit-YARN-Build/167//console

This message is automatically generated.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170-1.patch, YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Tom White (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13507289#comment-13507289 ] 

Tom White commented on YARN-170:
--------------------------------

+1

Vinod, do you have any more comments before we commit this?
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170-1.patch, YARN-170-2.patch, YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Tom White (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13505384#comment-13505384 ] 

Tom White commented on YARN-170:
--------------------------------

This looks like an overall improvement. A few minor comments on the latest patch:

* The reboot() method doesn't need to be public.
* The new classes are missing license headers.
* Please add a test for the change.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170-1.patch, YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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

[jira] [Commented] (YARN-170) NodeManager stop() gets called twice on shutdown

Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/YARN-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13507063#comment-13507063 ] 

Hadoop QA commented on YARN-170:
--------------------------------

{color:green}+1 overall{color}.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12555459/YARN-170-2.patch
  against trunk revision .

    {color:green}+1 @author{color}.  The patch does not contain any @author tags.

    {color:green}+1 tests included{color}.  The patch appears to include 1 new or modified test files.

    {color:green}+1 javac{color}.  The applied patch does not increase the total number of javac compiler warnings.

    {color:green}+1 javadoc{color}.  The javadoc tool did not generate any warning messages.

    {color:green}+1 eclipse:eclipse{color}.  The patch built with eclipse:eclipse.

    {color:green}+1 findbugs{color}.  The patch does not introduce any new Findbugs (version 1.3.9) warnings.

    {color:green}+1 release audit{color}.  The applied patch does not increase the total number of release audit warnings.

    {color:green}+1 core tests{color}.  The patch passed unit tests in hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager.

    {color:green}+1 contrib tests{color}.  The patch passed contrib unit tests.

Test results: https://builds.apache.org/job/PreCommit-YARN-Build/196//testReport/
Console output: https://builds.apache.org/job/PreCommit-YARN-Build/196//console

This message is automatically generated.
                
> NodeManager stop() gets called twice on shutdown
> ------------------------------------------------
>
>                 Key: YARN-170
>                 URL: https://issues.apache.org/jira/browse/YARN-170
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.0.2-alpha
>            Reporter: Sandy Ryza
>            Assignee: Sandy Ryza
>         Attachments: YARN-170-1.patch, YARN-170-2.patch, YARN-170.patch
>
>
> The stop method in the NodeManager gets called twice when the NodeManager is shut down via the shutdown hook.
> The first is the stop that gets called directly by the shutdown hook.  The second occurs when the NodeStatusUpdaterImpl is stopped.  The NodeManager responds to the NodeStatusUpdaterImpl stop stateChanged event by stopping itself.  This is so that NodeStatusUpdaterImpl can notify the NodeManager to stop, by stopping itself in response to a request from the ResourceManager
> This could be avoided if the NodeStatusUpdaterImpl were to stop the NodeManager by calling its stop method directly.

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