hadoop-mapreduce-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thamizhannal Paramasivam <thamizhanna...@gmail.com>
Subject reducer with MultipleTextOutputFormat issue
Date Fri, 27 Jan 2012 18:09:15 GMT
Hi All,

This is question regarding Hadoop-0.19 with MultipleTextOutputFormat. I am
using MyMultipleTextOutputFormat to write reducer output.
I am using 4 reducers. But, only one output of reducer's output has been
written into output file.
I have debugged this program by putting println() on reducer, it seems all
the reducer are getting <K,V>  as expected and writing results to
worOutputCollector. But out of which one of the reducer result only been
written on output file.

Any suggestion would be appreciated. If I put reducer=1 then it is working

public class MyMultipleTextOutputFormat<K, V> extends
        MultipleTextOutputFormat<K, V> {

    protected String generateFileNameForKeyValue(K key, V value, String
name) {
        String[] keys = key.toString().split("%");
        if ( keys.length != 3 ) {
            return key.toString();
        return keys[2].toString();


View raw message