tez-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bi...@apache.org
Subject git commit: TEZ-878. doAssignAll() in TaskScheduler ignores delayedContainers being out of sync with heldContainers (bikas)
Date Sat, 22 Feb 2014 20:31:26 GMT
Repository: incubator-tez
Updated Branches:
  refs/heads/master 0b04ccf2c -> 1752d553f


TEZ-878. doAssignAll() in TaskScheduler ignores delayedContainers being out of sync with heldContainers
(bikas)


Project: http://git-wip-us.apache.org/repos/asf/incubator-tez/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-tez/commit/1752d553
Tree: http://git-wip-us.apache.org/repos/asf/incubator-tez/tree/1752d553
Diff: http://git-wip-us.apache.org/repos/asf/incubator-tez/diff/1752d553

Branch: refs/heads/master
Commit: 1752d553f14906312d640b9a8884e2ed9fa0fce8
Parents: 0b04ccf
Author: Bikas Saha <bikas@apache.org>
Authored: Sat Feb 22 12:31:20 2014 -0800
Committer: Bikas Saha <bikas@apache.org>
Committed: Sat Feb 22 12:31:20 2014 -0800

----------------------------------------------------------------------
 .../java/org/apache/tez/dag/app/rm/TaskScheduler.java    | 11 +++++++++++
 1 file changed, 11 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tez/blob/1752d553/tez-dag/src/main/java/org/apache/tez/dag/app/rm/TaskScheduler.java
----------------------------------------------------------------------
diff --git a/tez-dag/src/main/java/org/apache/tez/dag/app/rm/TaskScheduler.java b/tez-dag/src/main/java/org/apache/tez/dag/app/rm/TaskScheduler.java
index 6ac9481..775d342 100644
--- a/tez-dag/src/main/java/org/apache/tez/dag/app/rm/TaskScheduler.java
+++ b/tez-dag/src/main/java/org/apache/tez/dag/app/rm/TaskScheduler.java
@@ -1551,6 +1551,17 @@ public class TaskScheduler extends AbstractService
           LOG.debug("Trying to assign all delayed containers to newly received"
             + " tasks");
         }
+        Iterator<HeldContainer> iter = delayedContainers.iterator();
+        while(iter.hasNext()) {
+          HeldContainer delayedContainer = iter.next();
+          if (!heldContainers.containsKey(delayedContainer.getContainer().getId())) {
+            // this container is no longer held by us
+            LOG.info("AssignAll - Skipping delayed container as container is no longer"
+                + " running, containerId="
+                + delayedContainer.getContainer().getId());
+            iter.remove();
+          }
+        }
         assignedContainers = tryAssignReUsedContainers(
           new ContainerIterable(delayedContainers));
       }


Mime
View raw message