code: public Task removeTask(ExecutionAttemptID executionAttemptID) {
  		checkInit();
  
  		TaskSlotMapping taskSlotMapping = taskSlotMappings.remove(executionAttemptID);
  
  		if (taskSlotMapping != null) {
  			Task task = taskSlotMapping.getTask();
  			TaskSlot taskSlot = taskSlotMapping.getTaskSlot();
  
  			taskSlot.remove(task.getExecutionId());
  
  			if (taskSlot.isReleasing() && taskSlot.isEmpty()) {
  				slotActions.freeSlot(taskSlot.getAllocationId());
  			}
  
  			return task;
  		} else {
  			return null;
  		}
  	}
docs: Remove the task with the given execution attempt id from its task slot. If the owning task
  slot is in state releasing and empty after removing the task, the slot is freed via the
  slot actions.
  
  @param executionAttemptID identifying the task to remove
  @return The removed task if there is any for the given execution attempt id; otherwise null