Quantcast

Question about Map Only AvroJob

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Question about Map Only AvroJob

hodgesz
Hi,

Is it possible to have a map only job take an Avro GenericRecord as input and output a non-Avro key/value text file?  The text file will contain a LongWritable key and a LongWritable value.

Thanks in advance,

Jonathan
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Question about Map Only AvroJob

Jeremy Lewi
Hi Jonathan,

Yes. Here's an example.

I was using a SpecificAvroRecord but I imagine it would work with GenericRecord just as well. 
The way I did it was to use a regular map reduce mapper and use AvroWrapper for the key and nothing for the value.

If you have questions let me know and I'll try to answer them.

J



On Mon, Sep 24, 2012 at 8:35 PM, hodgesz <[hidden email]> wrote:
Hi,

Is it possible to have a map only job take an Avro GenericRecord as input
and output a non-Avro key/value text file?  The text file will contain a
LongWritable key and a LongWritable value.

Thanks in advance,

Jonathan




--
View this message in context: http://apache-avro.679487.n3.nabble.com/Question-about-Map-Only-AvroJob-tp4025290.html
Sent from the Avro - Users mailing list archive at Nabble.com.

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Question about Map Only AvroJob

hodgesz
Awesome!  Thanks for your help.  That worked!

-Jonathan
Loading...