Description
Tasktracker is holdingup TaskStatus objects in runningTasks forever in somecases. This happens in the following scenario.
-> Task got an exception
-> Sets the phase to CLEANUP
-> The task tries to do cleanup. and it doesn't respond after that.
-> TaskTracker marks the task unresponsive and makes the task FAILED_UNCLEAN
-> TaskTracker doesn't remove it from runningTasks data structure, since phase is CLEANUP and state is FAILED_UNCLEAN (it treats this as cleanupAttempt).
I would propose that once the task goes to CLEANUP phase, kill on the task should mark it a clean failure i.e. The task state should be FAILED/KILLED.