Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
MapReduce >> mail # user >> output to file


Copy link to this message
-
Re: output to file
Matt,

You can extend ArrayWritable. Also use TextOutputFormat as the output
format.

In the TextOutputFormat key.toString() and value.toString() are called, so
override toString() in the subclass of ArrayWritable to get the desired
output format for the array. If toString() is not overridden then class
name and hex of the hash code is written to the output.

Regards,
Praveen

On Sun, Dec 4, 2011 at 6:56 PM, Matt Denn <[EMAIL PROTECTED]> wrote:

> I have an array computed in map stage and want its ouptut recorded or sent
> to file. Reducer can be naive and just send the output to file. Need to get
> a text output written to file for this array.
>