org.apache.nutch.crawl
Class GeneratorReducer
java.lang.Object
org.apache.hadoop.mapreduce.Reducer<K1,V1,K2,V2>
org.apache.gora.mapreduce.GoraReducer<GeneratorJob.SelectorEntry,WebPage,String,WebPage>
org.apache.nutch.crawl.GeneratorReducer
public class GeneratorReducer
- extends org.apache.gora.mapreduce.GoraReducer<GeneratorJob.SelectorEntry,WebPage,String,WebPage>
Reduce class for generate
The #reduce() method write a random integer to all generated URLs. This random
number is then used by FetcherJob.FetcherMapper
.
Methods inherited from class org.apache.gora.mapreduce.GoraReducer |
initReducerJob, initReducerJob, initReducerJob |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GeneratorReducer
public GeneratorReducer()
reduce
protected void reduce(GeneratorJob.SelectorEntry key,
Iterable<WebPage> values,
Reducer.Context context)
throws IOException,
InterruptedException
- Overrides:
reduce
in class Reducer<GeneratorJob.SelectorEntry,WebPage,String,WebPage>
- Throws:
IOException
InterruptedException
setup
protected void setup(Reducer.Context context)
throws IOException,
InterruptedException
- Overrides:
setup
in class Reducer<GeneratorJob.SelectorEntry,WebPage,String,WebPage>
- Throws:
IOException
InterruptedException
Copyright © 2012 The Apache Software Foundation