Chyler commented on a change in pull request #37: TEZ-4042: Speculative
attempts should avoid running on the same node
URL: https://github.com/apache/tez/pull/37#discussion_r258313359
##########
File path: tez-dag/src/main/java/org/apache/tez/dag/app/dag/impl/TaskImpl.java
##########
@@ -1009,14 +1014,18 @@ public TaskStateInternal transition(TaskImpl task,
TaskEvent event) {
public void transition(TaskImpl task, TaskEvent event) {
LOG.info("Scheduling a redundant attempt for task " + task.taskId);
task.counters.findCounter(TaskCounter.NUM_SPECULATIONS).increment(1);
- TezTaskAttemptID earliestUnfinishedAttempt = null;
+ TaskAttempt earliestUnfinishedAttempt = null;
for (TaskAttempt ta : task.attempts.values()) {
// find the oldest running attempt
if (!ta.isFinished()) {
- earliestUnfinishedAttempt = ta.getID();
+ earliestUnfinishedAttempt = ta;
}
}
- task.addAndScheduleAttempt(earliestUnfinishedAttempt);
+ NodeId nodeId = earliestUnfinishedAttempt.getNodeId();
+ task.unhealthyNodesHistory.add(nodeId);
Review comment:
for now there would be only one speculative attempt for one task, so maybe
putting the node ids of all running attempts is unnecessary?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services