org.apache.avro.mapred
Class AvroReducer<K,V,OUT>
java.lang.Object
org.apache.hadoop.conf.Configured
org.apache.avro.mapred.AvroReducer<K,V,OUT>
- All Implemented Interfaces:
- Configurable
public class AvroReducer<K,V,OUT>
- extends Configured
A reducer for Avro data.
Applications should subclass this class and pass their subclass to AvroJob.setReducerClass(org.apache.hadoop.mapred.JobConf, java.lang.Class extends org.apache.avro.mapred.AvroReducer>)
and perhaps AvroJob.setCombinerClass(org.apache.hadoop.mapred.JobConf, java.lang.Class extends org.apache.avro.mapred.AvroReducer>)
.
Subclasses override reduce(K, java.lang.Iterable, org.apache.avro.mapred.AvroCollector, org.apache.hadoop.mapred.Reporter)
.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AvroReducer
public AvroReducer()
reduce
public void reduce(K key,
Iterable<V> values,
AvroCollector<OUT> collector,
org.apache.hadoop.mapred.Reporter reporter)
throws IOException
- Called with all map output values with a given key. By default, pairs
key with each value, collecting
Pair
instances.
- Throws:
IOException
Copyright © 2010 The Apache Software Foundation