pig-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject svn commit: r616129 - in /incubator/pig/trunk: CHANGES.txt src/org/apache/pig/impl/PigContext.java
Date Tue, 29 Jan 2008 01:25:45 GMT
Author: gates
Date: Mon Jan 28 17:25:43 2008
New Revision: 616129

URL: http://svn.apache.org/viewvc?rev=616129&view=rev
Log:
PIG-69: NPE in PigContext.setJobtrackerLocation 


Modified:
    incubator/pig/trunk/CHANGES.txt
    incubator/pig/trunk/src/org/apache/pig/impl/PigContext.java

Modified: incubator/pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/incubator/pig/trunk/CHANGES.txt?rev=616129&r1=616128&r2=616129&view=diff
==============================================================================
--- incubator/pig/trunk/CHANGES.txt (original)
+++ incubator/pig/trunk/CHANGES.txt Mon Jan 28 17:25:43 2008
@@ -72,3 +72,5 @@
 	PIG-77: Added eclipse specific files to svn:ignore
 
 	PIG-57: Fixed NPE in PigContext.fixUpDomain (francisoud via gates)
+
+	PIG-69: NPE in PigContext.setJobtrackerLocation (francisoud via gates)

Modified: incubator/pig/trunk/src/org/apache/pig/impl/PigContext.java
URL: http://svn.apache.org/viewvc/incubator/pig/trunk/src/org/apache/pig/impl/PigContext.java?rev=616129&r1=616128&r2=616129&view=diff
==============================================================================
--- incubator/pig/trunk/src/org/apache/pig/impl/PigContext.java (original)
+++ incubator/pig/trunk/src/org/apache/pig/impl/PigContext.java Mon Jan 28 17:25:43 2008
@@ -74,7 +74,7 @@
     private ExecType execType;;    
 
     //  configuration for connecting to hadoop
-    transient private JobConf conf = null;        
+    transient private JobConf conf = new JobConf();
     
     //  extra jar files that are needed to run a job
     transient public List<URL> extraJars = new LinkedList<URL>();           
  
@@ -179,7 +179,6 @@
 		     	}
 			else
 			{
-				conf = new JobConf();
         			String cluster = System.getProperty("cluster");
         			if (cluster!=null && cluster.length() > 0){
 	        			if(cluster.indexOf(':') < 0) {
@@ -435,10 +434,14 @@
         return conf;
     }
 
+    @Deprecated
+    /** @deprecated use setConf() instead */
     public void setJobtrackerLocation(String newLocation) {
         conf.set("mapred.job.tracker", newLocation);
     }
 
+    @Deprecated
+    /** @deprecated use setConf() instead */
     public void setFilesystemLocation(String newLocation) {
         conf.set("fs.default.name", newLocation);
     }
@@ -605,5 +608,8 @@
 	public void setExecType(ExecType execType) {
 		this.execType = execType;
 	}
-		
+
+	public void setConf(JobConf conf) {
+		this.conf = conf;
+	}
 }



Mime
View raw message