pig-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From da...@apache.org
Subject svn commit: r1758708 - in /pig/trunk: CHANGES.txt shims/src/hadoop23/org/apache/pig/backend/hadoop23/PigJobControl.java
Date Thu, 01 Sep 2016 06:47:04 GMT
Author: daijy
Date: Thu Sep  1 06:47:04 2016
New Revision: 1758708

URL: http://svn.apache.org/viewvc?rev=1758708&view=rev
Log:
PIG-4967: NPE in PigJobControl.run() when job status is null

Modified:
    pig/trunk/CHANGES.txt
    pig/trunk/shims/src/hadoop23/org/apache/pig/backend/hadoop23/PigJobControl.java

Modified: pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1758708&r1=1758707&r2=1758708&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Thu Sep  1 06:47:04 2016
@@ -40,6 +40,8 @@ OPTIMIZATIONS
  
 BUG FIXES
 
+PIG-4967: NPE in PigJobControl.run() when job status is null (water via daijy)
+
 PIG-4972: StreamingIO_1 fail on perl 5.22 (daijy)
 
 PIG-4933: TestDataBagAccess.testBagConstantFlatten1/TestLogicalPlanBuilder.testQuery90 broken
after PIG-2315 (knoguchi)

Modified: pig/trunk/shims/src/hadoop23/org/apache/pig/backend/hadoop23/PigJobControl.java
URL: http://svn.apache.org/viewvc/pig/trunk/shims/src/hadoop23/org/apache/pig/backend/hadoop23/PigJobControl.java?rev=1758708&r1=1758707&r2=1758708&view=diff
==============================================================================
--- pig/trunk/shims/src/hadoop23/org/apache/pig/backend/hadoop23/PigJobControl.java (original)
+++ pig/trunk/shims/src/hadoop23/org/apache/pig/backend/hadoop23/PigJobControl.java Thu Sep
 1 06:47:04 2016
@@ -179,7 +179,18 @@ public class PigJobControl extends JobCo
           }
           while(it.hasNext()) {
             ControlledJob j = it.next();
-            log.debug("Checking state of job "+j);
+
+            // TODO: Need to re-visit the following try...catch
+            // when Pig picks up a Hadoop release with MAPREDUCE-6762 applied
+            // as its dependency.
+            try {
+              log.debug("Checking state of job " + j);
+            } catch(NullPointerException npe) {
+              log.warn("Failed to get job name " +
+                "when checking state of job. " +
+                "Check if job status is null.", npe);
+            }
+
             switch(checkState(j)) {
             case SUCCESS:
               getJobs(successfulJobs).add(j);



Mime
View raw message