hadoop-mapreduce-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ravigumm...@apache.org
Subject svn commit: r1303330 - in /hadoop/common/trunk/hadoop-mapreduce-project: CHANGES.txt src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/JobFactory.java
Date Wed, 21 Mar 2012 09:42:23 GMT
Author: ravigummadi
Date: Wed Mar 21 09:42:23 2012
New Revision: 1303330

URL: http://svn.apache.org/viewvc?rev=1303330&view=rev
Log:
MAPREDUCE-3953. [Gridmix] Gridmix throws NPE and does not simulate a job if the trace contains
null taskStatus for a task.(ravigummadi)

Modified:
    hadoop/common/trunk/hadoop-mapreduce-project/CHANGES.txt
    hadoop/common/trunk/hadoop-mapreduce-project/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/JobFactory.java

Modified: hadoop/common/trunk/hadoop-mapreduce-project/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-mapreduce-project/CHANGES.txt?rev=1303330&r1=1303329&r2=1303330&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-mapreduce-project/CHANGES.txt (original)
+++ hadoop/common/trunk/hadoop-mapreduce-project/CHANGES.txt Wed Mar 21 09:42:23 2012
@@ -52,6 +52,10 @@ Trunk (unreleased changes)
 
   BUG FIXES
 
+    MAPREDUCE-3953. [Gridmix] Gridmix throws NPE and does not simulate a
+                    job if the trace contains null taskStatus for a task.
+                    (ravigummadi)
+
     MAPREDUCE-3829. [Gridmix] Gridmix should give better error message when
                     input data directory already exists and -generate opton is
                     given.(ravigummadi)

Modified: hadoop/common/trunk/hadoop-mapreduce-project/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/JobFactory.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-mapreduce-project/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/JobFactory.java?rev=1303330&r1=1303329&r2=1303330&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-mapreduce-project/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/JobFactory.java
(original)
+++ hadoop/common/trunk/hadoop-mapreduce-project/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/JobFactory.java
Wed Mar 21 09:42:23 2012
@@ -215,7 +215,13 @@ abstract class JobFactory<T> implements 
     return null == job ? null : new FilterJobStory(job) {
       @Override
       public TaskInfo getTaskInfo(TaskType taskType, int taskNumber) {
-        return new MinTaskInfo(this.job.getTaskInfo(taskType, taskNumber));
+        TaskInfo info = this.job.getTaskInfo(taskType, taskNumber);
+        if (info != null) {
+          info = new MinTaskInfo(info);
+        } else {
+          info = new MinTaskInfo(new TaskInfo(0, 0, 0, 0, 0));
+        }
+        return info;
       }
     };
   }



Mime
View raw message