You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mapreduce-commits@hadoop.apache.org by cd...@apache.org on 2011/05/21 01:47:46 UTC
svn commit: r1125599 - in /hadoop/mapreduce/trunk: ./
src/java/org/apache/hadoop/mapred/
src/java/org/apache/hadoop/mapreduce/protocol/
src/test/mapred/org/apache/hadoop/mapred/
Author: cdouglas
Date: Fri May 20 23:47:45 2011
New Revision: 1125599
URL: http://svn.apache.org/viewvc?rev=1125599&view=rev
Log:
Revert MAPREDUCE-2470
Removed:
hadoop/mapreduce/trunk/src/test/mapred/org/apache/hadoop/mapred/TestNetworkedJob.java
Modified:
hadoop/mapreduce/trunk/CHANGES.txt
hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/JobClient.java
hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/RunningJob.java
hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/protocol/ClientProtocol.java
Modified: hadoop/mapreduce/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/CHANGES.txt?rev=1125599&r1=1125598&r2=1125599&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/CHANGES.txt (original)
+++ hadoop/mapreduce/trunk/CHANGES.txt Fri May 20 23:47:45 2011
@@ -214,9 +214,6 @@ Trunk (unreleased changes)
MAPREDUCE-2518. The t flag is missing in distcp help message. (Wei Yongjun
via szetszwo)
- MAPREDUCE-2470. Fix NPE in RunningJobs::getCounters. (Robert Joseph Evans
- via cdouglas)
-
MAPREDUCE-2514. Fix typo in TaskTracker ReinitTrackerAction log message.
(Jonathan Eagles via cdouglas)
Modified: hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/JobClient.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/JobClient.java?rev=1125599&r1=1125598&r2=1125599&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/JobClient.java (original)
+++ hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/JobClient.java Fri May 20 23:47:45 2011
@@ -42,6 +42,8 @@ import org.apache.hadoop.mapreduce.util.
import org.apache.hadoop.fs.FileSystem;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.io.Text;
+import org.apache.hadoop.ipc.RemoteException;
+import org.apache.hadoop.security.AccessControlException;
import org.apache.hadoop.security.token.Token;
import org.apache.hadoop.security.token.SecretManager.InvalidToken;
import org.apache.hadoop.util.Tool;
@@ -147,7 +149,7 @@ public class JobClient extends CLI {
* a JobProfile object to provide some info, and interacts with the
* remote service to provide certain functionality.
*/
- static class NetworkedJob implements RunningJob {
+ class NetworkedJob implements RunningJob {
Job job;
/**
* We store a JobProfile and a timestamp for when we last
@@ -156,7 +158,7 @@ public class JobClient extends CLI {
* has completely forgotten about the job. (eg, 24 hours after the
* job completes.)
*/
- public NetworkedJob(JobStatus status, Cluster cluster) throws IOException {
+ public NetworkedJob(JobStatus status) throws IOException {
job = Job.getInstance(cluster, status, new JobConf(status.getJobFile()));
}
@@ -378,12 +380,7 @@ public class JobClient extends CLI {
*/
public Counters getCounters() throws IOException {
try {
- Counters result = null;
- org.apache.hadoop.mapreduce.Counters temp = job.getCounters();
- if(temp != null) {
- result = Counters.downgrade(temp);
- }
- return result;
+ return Counters.downgrade(job.getCounters());
} catch (InterruptedException ie) {
throw new IOException(ie);
}
@@ -560,7 +557,7 @@ public class JobClient extends CLI {
if (job != null) {
JobStatus status = JobStatus.downgrade(job.getStatus());
if (status != null) {
- return new NetworkedJob(status, cluster);
+ return new NetworkedJob(status);
}
}
} catch (InterruptedException ie) {
Modified: hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/RunningJob.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/RunningJob.java?rev=1125599&r1=1125598&r2=1125599&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/RunningJob.java (original)
+++ hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/RunningJob.java Fri May 20 23:47:45 2011
@@ -193,7 +193,7 @@ public interface RunningJob {
/**
* Gets the counters for this job.
*
- * @return the counters for this job or null if the job has been retired.
+ * @return the counters for this job.
* @throws IOException
*/
public Counters getCounters() throws IOException;
Modified: hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/protocol/ClientProtocol.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/protocol/ClientProtocol.java?rev=1125599&r1=1125598&r2=1125599&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/protocol/ClientProtocol.java (original)
+++ hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/protocol/ClientProtocol.java Fri May 20 23:47:45 2011
@@ -230,7 +230,7 @@ public interface ClientProtocol extends
/**
* Get task completion events for the jobid, starting from fromEventId.
- * Returns empty array if no events are available.
+ * Returns empty aray if no events are available.
* @param jobid job id
* @param fromEventId event id to start from.
* @param maxEvents the max number of events we want to look at