There is a slightly cleaner way to write this:

    val activeTasks = executorToTasksActive.getOrElseUpdate(eid, new HashSet[TaskInfo]())
    activeTasks += taskStart.taskInfo