You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mapreduce-user@hadoop.apache.org by xeonmailinglist-gmail <xe...@gmail.com> on 2015/04/13 02:39:35 UTC
What the class GenericMRLoadGenerator.java does?
Hi
I am trying to understand what the
|/src/test/org/apache/hadoop/mapred/GenericMRLoadGenerator.java| does. I
have noticed that the map and reduce functions uses this method, but I
don’t understand what it does. What is the purpose of this class? What
this method is doing?
|
protected void emit(K key, V val, OutputCollector<K,V> out)
throws IOException {
++total;
while((float) kept / total < keep) {
++kept;
out.collect(key, val);
}
}
}
|
--
--