Uploaded image for project: 'Hadoop YARN'
  1. Hadoop YARN
  2. YARN-6683

Invalid event: COLLECTOR_UPDATE at KILLED

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.0.0-alpha4
    • Component/s: None
    • Labels:
      None

      Description

      2017-06-01 20:01:22,686 ERROR rmapp.RMAppImpl (RMAppImpl.java:handle(905)) - Can't handle this event at current state
      org.apache.hadoop.yarn.state.InvalidStateTransitionException: Invalid event: COLLECTOR_UPDATE at KILLED
              at org.apache.hadoop.yarn.state.StateMachineFactory.doTransition(StateMachineFactory.java:305)
              at org.apache.hadoop.yarn.state.StateMachineFactory.access$300(StateMachineFactory.java:46)
              at org.apache.hadoop.yarn.state.StateMachineFactory$InternalStateMachine.doTransition(StateMachineFactory.java:448)
              at org.apache.hadoop.yarn.server.resourcemanager.rmapp.RMAppImpl.handle(RMAppImpl.java:903)
              at org.apache.hadoop.yarn.server.resourcemanager.rmapp.RMAppImpl.handle(RMAppImpl.java:118)
              at org.apache.hadoop.yarn.server.resourcemanager.ResourceManager$ApplicationEventDispatcher.handle(ResourceManager.java:904)
              at org.apache.hadoop.yarn.server.resourcemanager.ResourceManager$ApplicationEventDispatcher.handle(ResourceManager.java:888)
              at org.apache.hadoop.yarn.event.AsyncDispatcher.dispatch(AsyncDispatcher.java:201)
              at org.apache.hadoop.yarn.event.AsyncDispatcher$1.run(AsyncDispatcher.java:127)
      

      Below code already gets the RMApp instance and then send an event to RMApp to update the collector address. Instead of updating via event, it could just update via a method of RMApp. This also avoids state-machine changes.
      Also, is there any implications that COLLECTOR_UPDATE happened at KILLED state ?

                } else {
                  String previousCollectorAddr = rmApp.getCollectorAddr();
                  if (previousCollectorAddr == null
                      || !previousCollectorAddr.equals(collectorAddr)) {
                    // sending collector update event.
                    RMAppCollectorUpdateEvent event =
                        new RMAppCollectorUpdateEvent(appId, collectorAddr);
                    rmContext.getDispatcher().getEventHandler().handle(event);
                  }
                }
      

        Attachments

        1. YARN-6683.001.patch
          10 kB
          Rohith Sharma K S
        2. YARN-6683.001.patch
          10 kB
          Rohith Sharma K S

          Activity

            People

            • Assignee:
              rohithsharma Rohith Sharma K S
              Reporter:
              jianhe Jian He
            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: