You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by "W.P. McNeill" <bi...@gmail.com> on 2011/11/02 19:23:52 UTC

Do I need to write a raw comparator for a Writable collection class?

I have a custom MyWritable < Writable object for which I have written a
custom WritableComparator. I am putting MyWritable inside a MyArrayWritable
< ArrayWritable so that I can use lists of these objects as MapReduce keys.
Do I need to write a custom comparator for MyArrayWritable too?

>From looking at the source, it appears the answer is yes, but I wanted to
double-check, because it seems like there could be a generic implementation.