AM启动--ContainerStartedTransition(一)

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/zhusirong/article/details/83782644

ContainerStartedTransition(基于hadoop 2.7.6)

经过ContainerStartedTransition转换器处理后,RMContainerState状态由NEW转换为ALLOCATED.

单纯,代码清单:

private static final class ContainerStartedTransition extends
      BaseTransition {

    @Override
    public void transition(RMContainerImpl container, RMContainerEvent event) {
      container.eventHandler.handle(new RMAppAttemptEvent(
          container.appAttemptId, RMAppAttemptEventType.CONTAINER_ALLOCATED));
    }
  }

ContainerStartedTransition是RMContainerEventType.START事件的转换处理器,START事件是完成分配时触发(FiCaSchedulerApp.allocate),该转换处理器主要是触发RMAppAttemptEventType.CONTAINER_ALLOCATED事件.

猜你喜欢

转载自blog.csdn.net/zhusirong/article/details/83782644
am