hadoop-mapreduce-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cdoug...@apache.org
Subject svn commit: r825027 - in /hadoop/mapreduce/trunk: CHANGES.txt src/java/org/apache/hadoop/mapreduce/jobhistory/EventReader.java
Date Wed, 14 Oct 2009 06:42:28 GMT
Author: cdouglas
Date: Wed Oct 14 06:42:27 2009
New Revision: 825027

URL: http://svn.apache.org/viewvc?rev=825027&view=rev
Log:
MAPREDUCE-1071. Use DataInputStream rather than FSDataInputStream in the
JobHistory EventReader. Contributed by Hong Tang

Modified:
    hadoop/mapreduce/trunk/CHANGES.txt
    hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/jobhistory/EventReader.java

Modified: hadoop/mapreduce/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/CHANGES.txt?rev=825027&r1=825026&r2=825027&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/CHANGES.txt (original)
+++ hadoop/mapreduce/trunk/CHANGES.txt Wed Oct 14 06:42:27 2009
@@ -752,4 +752,6 @@
     MAPREDUCE-1030. Modified scheduling algorithm to return a map and reduce
     task per heartbeat in the capacity scheduler.
     (Rahul Kumar Singh via yhemanth)
- 
+
+    MAPREDUCE-1071. Use DataInputStream rather than FSDataInputStream in the
+    JobHistory EventReader. (Hong Tang via cdouglas)

Modified: hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/jobhistory/EventReader.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/jobhistory/EventReader.java?rev=825027&r1=825026&r2=825027&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/jobhistory/EventReader.java
(original)
+++ hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/jobhistory/EventReader.java
Wed Oct 14 06:42:27 2009
@@ -18,10 +18,11 @@
 
 package org.apache.hadoop.mapreduce.jobhistory;
 
+import java.io.Closeable;
+import java.io.DataInputStream;
 import java.io.IOException;
 import java.io.EOFException;
 
-import org.apache.hadoop.fs.FSDataInputStream;
 import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.mapreduce.Counter;
@@ -34,10 +35,10 @@
 import org.apache.avro.io.DatumReader;
 import org.apache.avro.specific.SpecificDatumReader;
 
-public class EventReader {
+public class EventReader implements Closeable {
   private String version;
   private Schema schema;
-  private FSDataInputStream in;
+  private DataInputStream in;
   private Decoder decoder;
   private DatumReader reader;
 
@@ -57,7 +58,7 @@
    * @throws IOException
    */
   @SuppressWarnings("deprecation")
-  public EventReader(FSDataInputStream in) throws IOException {
+  public EventReader(DataInputStream in) throws IOException {
     this.in = in;
     this.version = in.readLine();
     
@@ -153,6 +154,7 @@
    * Close the Event reader
    * @throws IOException
    */
+  @Override
   public void close() throws IOException {
     if (in != null) {
       in.close();



Mime
View raw message