Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This describes how the state machine works internally.  What is important to know is that the addTransition method takes the preState, postState, eventType, and transition.  The transition is an object whose transition method will be called during the doTransition method (called by the event handler).

Hadoop MapReduce State Machine Redundancy

JobImpl
CountTransitionTrigger (Event/State)Comment
12DIAGNOSTIC_UPDATE_TRANSITION

JobEventType.JOB_DIAGNOSTIC_UPDATE

Same for most named states (JobImpl)
14COUNTER_UPDATE_TRANSITIONJobEventType.JOB_COUNTER_UPDATE 
13

INTERNAL_ERROR_TRANSITION

JobEventType.INTERNAL_ERROR

InternalErrorTransition extends InternalTerminationTransition by setting the error into the history string.

5INTERNAL_REBOOT_TRANSITIONJobEventType.JOB_AM_REBOOT

InternalRebootTransition extends InternalTerminationTransition by setting the error in the history string.

2

TASK_ATTEMPT_COMPLETED_EVENT_TRANSITION

JobEventType.JOB_TASK_ATTEMPT_COMPLETED

 
2

KilledDuringAbortTransition()

JobEventType.JOB_KILL

From FAIL_WAIT and FAIL_ABORT
2

JobAbortCompletedTransition()

JobEventType.JOB_ABORT_COMPLETEDFrom FAIL_ABORT and KILL_ABORT
TaskImpl
CountTransitionTriggerComment
2

KILL_TRANSITION

TaskEventType.T_KILL 
2

ATTEMPT_KILLED_TRANSITION

TaskEventType.T_ATTEMPT_KILLED 
2

AttemptFailedTransition()

TaskEventType.T_ATTEMPT_FAILED 
TaskAttemptImpl
CountTransitionTriggerComment
2

RequestContainerTransition()

TaskAttemptEventType.TA_SCHEDULE

TaskAttemptEventType.TA_RESCHEDULE

A bool is passed to the constructor to do cleanup in one case and no the other
4

KilledTransition()

TaskAttemptEventType.TA_KILL

TaskAttemptEventType.TA_CONTAINER_CLEANED

TaskAttemptEventType.TA_CLEANUP_DONE

 
2

FailedTransition()

TaskAttemptEventType.TA_FAILMSG

TaskAttemptEventType.TA_CLEANUP_DONE

 
13

DIAGNOSTIC_INFORMATION_UPDATE_TRANSITION

TaskAttemptEventType.TA_DIAGNOSTICS_UPDATE

 
3DeallocateContainerTransition()

TaskAttemptEventType.TA_KILL

TaskAttemptEventType.TA_FAILMSG

TaskAttemptEventType.TA_CONTAINER_LAUNCH_FAILED

Constructor takes a bool that will "send event to speculator that we withdraw our container needs, if we're transitioning out of UNASSIGNED"
13CLEANUP_CONTAINER_TRANSITION

TaskAttemptEventType.TA_CONTAINER_COMPLETED

TaskAttemptEventType.TA_KILL

TaskAttemptEventType.TA_FAILMSG

TaskAttemptEventType.TA_DONE

TaskAttemptEventType.TA_TIMED_OUT

 
2

StatusUpdater()

TaskAttemptEventType.TA_UPDATE

 
2TaskCleanupTransition()TaskAttemptEventType.TA_CONTAINER_CLEANED 

Additional Notes:

  • Event "ignore" lists is necessary in this implementation for events that come in that shouldn't affect the state machine.

No support list in Python MapReduce

  • Diagnostics/Logs
  • Counters
  • Doesn't support reboot