hadoop-mapreduce-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xeonmailinglist-gmail <xeonmailingl...@gmail.com>
Subject What the class GenericMRLoadGenerator.java does?
Date Mon, 13 Apr 2015 00:39:35 GMT
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);
       }
     }
   }
|

​

-- 
--


Mime
View raw message