hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-6061) Add a customized uncaughtexceptionhandler for critical threads in RM
Date Wed, 01 Feb 2017 17:03:51 GMT

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

ASF GitHub Bot commented on YARN-6061:
--------------------------------------

Github user kambatla commented on a diff in the pull request:

    https://github.com/apache/hadoop/pull/182#discussion_r98942361
  
    --- Diff: hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/ResourceManager.java
---
    @@ -824,25 +824,29 @@ public void handle(RMFatalEvent event) {
        * Transition to standby in a new thread.
        */
       public void handleTransitionToStandByInNewThread() {
    -    new Thread() {
    -      @Override
    -      public void run() {
    -        if (rmContext.isHAEnabled()) {
    -          try {
    -            // Transition to standby and reinit active services
    -            LOG.info("Transitioning RM to Standby mode");
    -            transitionToStandby(true);
    -            EmbeddedElector elector = rmContext.getLeaderElectorService();
    -            if (elector != null) {
    -              elector.rejoinElection();
    -            }
    -          } catch (Exception e) {
    -            LOG.fatal("Failed to transition RM to Standby mode.", e);
    -            ExitUtil.terminate(1, e);
    +    Thread standByTransitionThread = new Thread(new StandByTransitionThread());
    +    standByTransitionThread.setName("StandByTransitionThread Handler");
    +    standByTransitionThread.start();
    +  }
    +
    +  private class StandByTransitionThread implements Runnable {
    --- End diff --
    
    Naming the Runnable a Thread sounds confusing. Can we change it to TransitionToStandbyRunnable
or some such? 


> Add a customized uncaughtexceptionhandler for critical threads in RM
> --------------------------------------------------------------------
>
>                 Key: YARN-6061
>                 URL: https://issues.apache.org/jira/browse/YARN-6061
>             Project: Hadoop YARN
>          Issue Type: Improvement
>          Components: resourcemanager
>            Reporter: Yufei Gu
>            Assignee: Yufei Gu
>         Attachments: YARN-6061.001.patch, YARN-6061.002.patch, YARN-6061.003.patch, YARN-6061.004.patch,
YARN-6061.005.patch
>
>
> There are several threads in fair scheduler. The thread will quit when there is a runtime
exception inside it. We should bring down the RM when that happens. Otherwise, there may be
some weird behavior in RM. 



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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


Mime
View raw message