public static class WordMedian.WordMedianReducer extends org.apache.hadoop.mapreduce.Reducer<IntWritable,IntWritable,IntWritable,IntWritable>
org.apache.hadoop.mapreduce.Reducer.Context| Constructor and Description |
|---|
WordMedianReducer() |
| Modifier and Type | Method and Description |
|---|---|
void |
reduce(IntWritable key,
Iterable<IntWritable> values,
org.apache.hadoop.mapreduce.Reducer.Context context)
Sums all the individual values within the iterator and writes them to the
same key.
|
cleanup, run, setuppublic void reduce(IntWritable key, Iterable<IntWritable> values, org.apache.hadoop.mapreduce.Reducer.Context context) throws IOException, InterruptedException
reduce in class org.apache.hadoop.mapreduce.Reducer<IntWritable,IntWritable,IntWritable,IntWritable>key - This will be a length of a word that was read.values - This will be an iterator of all the values associated with that
key.IOExceptionInterruptedExceptionCopyright © 2018 CERN. All Rights Reserved.