hadoop-mapreduce-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r830823 - in /hadoop/mapreduce/branches/branch-0.21: CHANGES.txt src/contrib/fairscheduler/src/java/org/apache/hadoop/mapred/FairScheduler.java
Date Thu, 29 Oct 2009 01:31:23 GMT
Author: matei
Date: Thu Oct 29 01:31:23 2009
New Revision: 830823

URL: http://svn.apache.org/viewvc?rev=830823&view=rev
Log:
MAPREDUCE-1089. Fix NPE in fair scheduler preemption when tasks are  
scheduled but not running. Contributed by Todd Lipcon.


Modified:
    hadoop/mapreduce/branches/branch-0.21/CHANGES.txt
    hadoop/mapreduce/branches/branch-0.21/src/contrib/fairscheduler/src/java/org/apache/hadoop/mapred/FairScheduler.java

Modified: hadoop/mapreduce/branches/branch-0.21/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/branches/branch-0.21/CHANGES.txt?rev=830823&r1=830822&r2=830823&view=diff
==============================================================================
--- hadoop/mapreduce/branches/branch-0.21/CHANGES.txt (original)
+++ hadoop/mapreduce/branches/branch-0.21/CHANGES.txt Thu Oct 29 01:31:23 2009
@@ -424,6 +424,9 @@
 
   BUG FIXES
 
+    MAPREDUCE-1089. Fix NPE in fair scheduler preemption when tasks are  
+    scheduled but not running. (Todd Lipcon via matei)
+
     MAPREDUCE-878. Rename fair scheduler design doc to 
     fair-scheduler-design-doc.tex and add Apache license header (matei)
 

Modified: hadoop/mapreduce/branches/branch-0.21/src/contrib/fairscheduler/src/java/org/apache/hadoop/mapred/FairScheduler.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/branches/branch-0.21/src/contrib/fairscheduler/src/java/org/apache/hadoop/mapred/FairScheduler.java?rev=830823&r1=830822&r2=830823&view=diff
==============================================================================
--- hadoop/mapreduce/branches/branch-0.21/src/contrib/fairscheduler/src/java/org/apache/hadoop/mapred/FairScheduler.java
(original)
+++ hadoop/mapreduce/branches/branch-0.21/src/contrib/fairscheduler/src/java/org/apache/hadoop/mapred/FairScheduler.java
Thu Oct 29 01:31:23 2009
@@ -831,7 +831,11 @@
     List<TaskStatus> statuses = new ArrayList<TaskStatus>();
     for (TaskInProgress tip: tips) {
       for (TaskAttemptID id: tip.getActiveTasks().keySet()) {
-        statuses.add(tip.getTaskStatus(id));
+        TaskStatus stat = tip.getTaskStatus(id);
+        // status is null when the task has been scheduled but not yet running
+        if (stat != null) {
+          statuses.add(stat);
+        }
       }
     }
     return statuses;



Mime
View raw message