Java Code Examples for org.apache.hadoop.yarn.state.SingleArcTransition

The following examples show how to use org.apache.hadoop.yarn.state.SingleArcTransition. These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source Project: hadoop   Source File: RMAppImpl.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public RMAppState transition(RMAppImpl app, RMAppEvent event) {
  if (app.transitionTodo instanceof SingleArcTransition) {
    ((SingleArcTransition) app.transitionTodo).transition(app,
      app.eventCausingFinalSaving);
  } else if (app.transitionTodo instanceof MultipleArcTransition) {
    ((MultipleArcTransition) app.transitionTodo).transition(app,
      app.eventCausingFinalSaving);
  }
  return app.targetedFinalState;

}
 
Example 2
Source Project: hadoop   Source File: RMAppAttemptImpl.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public RMAppAttemptState transition(RMAppAttemptImpl appAttempt,
    RMAppAttemptEvent event) {
  RMAppAttemptEvent causeEvent = appAttempt.eventCausingFinalSaving;

  if (appAttempt.transitionTodo instanceof SingleArcTransition) {
    ((SingleArcTransition) appAttempt.transitionTodo).transition(
      appAttempt, causeEvent);
  } else if (appAttempt.transitionTodo instanceof MultipleArcTransition) {
    ((MultipleArcTransition) appAttempt.transitionTodo).transition(
      appAttempt, causeEvent);
  }
  return appAttempt.targetedFinalState;
}
 
Example 3
Source Project: big-c   Source File: RMAppImpl.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public RMAppState transition(RMAppImpl app, RMAppEvent event) {
  if (app.transitionTodo instanceof SingleArcTransition) {
    ((SingleArcTransition) app.transitionTodo).transition(app,
      app.eventCausingFinalSaving);
  } else if (app.transitionTodo instanceof MultipleArcTransition) {
    ((MultipleArcTransition) app.transitionTodo).transition(app,
      app.eventCausingFinalSaving);
  }
  return app.targetedFinalState;

}
 
Example 4
Source Project: big-c   Source File: RMAppAttemptImpl.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public RMAppAttemptState transition(RMAppAttemptImpl appAttempt,
    RMAppAttemptEvent event) {
  RMAppAttemptEvent causeEvent = appAttempt.eventCausingFinalSaving;

  if (appAttempt.transitionTodo instanceof SingleArcTransition) {
    ((SingleArcTransition) appAttempt.transitionTodo).transition(
      appAttempt, causeEvent);
  } else if (appAttempt.transitionTodo instanceof MultipleArcTransition) {
    ((MultipleArcTransition) appAttempt.transitionTodo).transition(
      appAttempt, causeEvent);
  }
  return appAttempt.targetedFinalState;
}