incubator-crunch-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jwi...@apache.org
Subject git commit: CRUNCH-146: Remove extension checking from AvroInputFormat. Contributed by Dave Beech.
Date Thu, 17 Jan 2013 14:52:04 GMT
Updated Branches:
  refs/heads/master 438e36a38 -> 5fe2f68b7


CRUNCH-146: Remove extension checking from AvroInputFormat. Contributed by Dave Beech.


Project: http://git-wip-us.apache.org/repos/asf/incubator-crunch/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-crunch/commit/5fe2f68b
Tree: http://git-wip-us.apache.org/repos/asf/incubator-crunch/tree/5fe2f68b
Diff: http://git-wip-us.apache.org/repos/asf/incubator-crunch/diff/5fe2f68b

Branch: refs/heads/master
Commit: 5fe2f68b79aa5cd21756619cdc76764b7d502aa5
Parents: 438e36a
Author: Josh Wills <jwills@apache.org>
Authored: Thu Jan 17 06:41:51 2013 -0800
Committer: Josh Wills <jwills@apache.org>
Committed: Thu Jan 17 06:49:53 2013 -0800

----------------------------------------------------------------------
 .../apache/crunch/types/avro/AvroInputFormat.java  |   17 ---------------
 1 files changed, 0 insertions(+), 17 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-crunch/blob/5fe2f68b/crunch/src/main/java/org/apache/crunch/types/avro/AvroInputFormat.java
----------------------------------------------------------------------
diff --git a/crunch/src/main/java/org/apache/crunch/types/avro/AvroInputFormat.java b/crunch/src/main/java/org/apache/crunch/types/avro/AvroInputFormat.java
index 59c1862..b8bbebd 100644
--- a/crunch/src/main/java/org/apache/crunch/types/avro/AvroInputFormat.java
+++ b/crunch/src/main/java/org/apache/crunch/types/avro/AvroInputFormat.java
@@ -18,34 +18,18 @@
 package org.apache.crunch.types.avro;
 
 import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
 
 import org.apache.avro.Schema;
 import org.apache.avro.mapred.AvroJob;
 import org.apache.avro.mapred.AvroWrapper;
-import org.apache.hadoop.fs.FileStatus;
 import org.apache.hadoop.io.NullWritable;
 import org.apache.hadoop.mapreduce.InputSplit;
-import org.apache.hadoop.mapreduce.JobContext;
 import org.apache.hadoop.mapreduce.RecordReader;
 import org.apache.hadoop.mapreduce.TaskAttemptContext;
 import org.apache.hadoop.mapreduce.lib.input.FileInputFormat;
 
 /** An {@link org.apache.hadoop.mapreduce.InputFormat} for Avro data files. */
 public class AvroInputFormat<T> extends FileInputFormat<AvroWrapper<T>, NullWritable>
{
-
-  @Override
-  protected List<FileStatus> listStatus(JobContext job) throws IOException {
-    List<FileStatus> result = new ArrayList<FileStatus>();
-    for (FileStatus file : super.listStatus(job)) {
-      if (file.getPath().getName().endsWith(org.apache.avro.mapred.AvroOutputFormat.EXT))
{
-        result.add(file);
-      }
-    }
-    return result;
-  }
-
   @Override
   public RecordReader<AvroWrapper<T>, NullWritable> createRecordReader(InputSplit
split, TaskAttemptContext context)
       throws IOException, InterruptedException {
@@ -54,5 +38,4 @@ public class AvroInputFormat<T> extends FileInputFormat<AvroWrapper<T>,
NullWrit
     Schema schema = new Schema.Parser().parse(jsonSchema);
     return new AvroRecordReader<T>(schema);
   }
-
 }


Mime
View raw message