hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cutt...@apache.org
Subject svn commit: r472709 - in /lucene/hadoop/trunk: CHANGES.txt src/java/org/apache/hadoop/mapred/JobTracker.java
Date Thu, 09 Nov 2006 00:03:06 GMT
Author: cutting
Date: Wed Nov  8 16:03:05 2006
New Revision: 472709

URL: http://svn.apache.org/viewvc?view=rev&rev=472709
Log:
HADOOP-694.  Fix a NullPointerException in jobtracker.  Contributed by Mahadev.

Modified:
    lucene/hadoop/trunk/CHANGES.txt
    lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/JobTracker.java

Modified: lucene/hadoop/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/CHANGES.txt?view=diff&rev=472709&r1=472708&r2=472709
==============================================================================
--- lucene/hadoop/trunk/CHANGES.txt (original)
+++ lucene/hadoop/trunk/CHANGES.txt Wed Nov  8 16:03:05 2006
@@ -31,6 +31,9 @@
  9. HADOOP-459.  Fix memory leaks and a host of other issues with
     libhdfs.  (Sameer Paranjpye via cutting)
 
+10. HADOOP-694.  Fix a NullPointerException in jobtracker.
+    (Mahadev Konar via cutting)
+
 
 Release 0.8.0 - 2006-11-03
 

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/JobTracker.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/JobTracker.java?view=diff&rev=472709&r1=472708&r2=472709
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/JobTracker.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/JobTracker.java Wed Nov  8 16:03:05
2006
@@ -140,11 +140,16 @@
                       String trackerName = getAssignedTracker(taskId);
                       TaskTrackerStatus trackerStatus = 
                         getTaskTracker(trackerName);
-                      job.failedTask(tip, taskId, "Error launching task", 
-                                     tip.isMapTask()? TaskStatus.Phase.MAP:
-                                       TaskStatus.Phase.STARTING,
-                                     trackerStatus.getHost(), trackerName,
-                                     myMetrics);
+                      // This might happen when the tasktracker has already
+                      // expired and this thread tries to call failedtask
+                      // again. expire tasktracker should have called failed
+                      // task!
+                      if (trackerStatus != null)
+                        job.failedTask(tip, taskId, "Error launching task", 
+                                       tip.isMapTask()? TaskStatus.Phase.MAP:
+                                         TaskStatus.Phase.STARTING,
+                                       trackerStatus.getHost(), trackerName,
+                                       myMetrics);
                     }
                     itr.remove();
                   } else {



Mime
View raw message