myriad-scheduler/src/main/java/org/apache/myriad/scheduler/yarn/MyriadCapacityScheduler.java [43:83]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    super();
  }

  /**
   * Register an event handler that receives {@link RMNodeEvent} events.
   * This event handler is registered ahead of RM's own event handler for RMNodeEvents.
   * For e.g. myriad can inspect a node's HB (RMNodeStatusEvent) before the HB is handled by
   * RM and the scheduler.
   *
   * @param rmContext
   */
  @Override
  public synchronized void setRMContext(RMContext rmContext) {
    this.rmContext = rmContext;
    this.yarnSchedulerInterceptor = new CompositeInterceptor();
    rmNodeEventHandler = new RMNodeEventHandler(yarnSchedulerInterceptor, rmContext);
    rmContext.getDispatcher().register(RMNodeEventType.class, rmNodeEventHandler);
    super.setRMContext(rmContext);
  }

  /**
   * ******** Methods overridden from YARN {@link CapacityScheduler}  *********************
   */

  @Override
  public synchronized void serviceInit(Configuration conf) throws Exception {
    this.conf = conf;
    super.serviceInit(conf);
  }

  @Override
  public synchronized void serviceStart() throws Exception {
    this.yarnSchedulerInterceptor.init(conf, this, rmContext);
    super.serviceStart();
  }

  @Override
  public synchronized void handle(SchedulerEvent event) {
    this.yarnSchedulerInterceptor.beforeSchedulerEventHandled(event);
    super.handle(event);
    this.yarnSchedulerInterceptor.afterSchedulerEventHandled(event);
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



myriad-scheduler/src/main/java/org/apache/myriad/scheduler/yarn/MyriadFifoScheduler.java [43:83]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    super();
  }

  /**
   * Register an event handler that receives {@link RMNodeEvent} events.
   * This event handler is registered ahead of RM's own event handler for RMNodeEvents.
   * For e.g. myriad can inspect a node's HB (RMNodeStatusEvent) before the HB is handled by
   * RM and the scheduler.
   *
   * @param rmContext
   */
  @Override
  public synchronized void setRMContext(RMContext rmContext) {
    this.rmContext = rmContext;
    this.yarnSchedulerInterceptor = new CompositeInterceptor();
    rmNodeEventHandler = new RMNodeEventHandler(yarnSchedulerInterceptor, rmContext);
    rmContext.getDispatcher().register(RMNodeEventType.class, rmNodeEventHandler);
    super.setRMContext(rmContext);
  }

  /**
   * ******** Methods overridden from YARN {@link FifoScheduler}  *********************
   */

  @Override
  public synchronized void serviceInit(Configuration conf) throws Exception {
    this.conf = conf;
    super.serviceInit(conf);
  }

  @Override
  public synchronized void serviceStart() throws Exception {
    this.yarnSchedulerInterceptor.init(conf, this, rmContext);
    super.serviceStart();
  }

  @Override
  public synchronized void handle(SchedulerEvent event) {
    this.yarnSchedulerInterceptor.beforeSchedulerEventHandled(event);
    super.handle(event);
    this.yarnSchedulerInterceptor.afterSchedulerEventHandled(event);
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



