FAQ
I am wondering whether it is possible to deserialize the keys and values in a hadoop output file where the output format is SequenceFileOutputFormat.

many thanks!

Search Discussions

  • Chen, Young at Jun 3, 2008 at 12:19 pm
    Do you mean read output file which create by SequenceFile.createWriter? If so, maybe below code part will be useful. It reads out long integer number out from sequence file.

    SequenceFile.Reader reader = new SequenceFile.Reader(fileSys, inFile, jobConf);
    LongWritable numInside = new LongWritable();
    LongWritable numOutside = new LongWritable();
    reader.next(numInside, numOutside);

    -----Original Message-----
    From: Lin Guo
    Sent: 2008年6月3日 18:17
    To: core-user@hadoop.apache.org
    Subject: how to deserialize the contents of hadoop output (sequencefileoutputformat)

    I am wondering whether it is possible to deserialize the keys and values in a hadoop output file where the output format is SequenceFileOutputFormat.

    many thanks!
  • Stuart Sierra at Jun 3, 2008 at 2:39 pm

    On Tue, Jun 3, 2008 at 6:17 AM, Lin Guo wrote:
    I am wondering whether it is possible to deserialize the keys and values in a hadoop output file where the output format is SequenceFileOutputFormat.
    I wrote some code to do this, samples attached.
    -Stuart
  • Chris Douglas at Jun 3, 2008 at 5:57 pm
    If your keys and values have meaningful toString methods, hadoop fs -
    text <path> will print the contents to stdout. -C
    On Jun 3, 2008, at 3:17 AM, Lin Guo wrote:

    I am wondering whether it is possible to deserialize the keys and
    values in a hadoop output file where the output format is
    SequenceFileOutputFormat.

    many thanks!

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupcommon-user @
categorieshadoop
postedJun 3, '08 at 11:08a
activeJun 3, '08 at 5:57p
posts4
users4
websitehadoop.apache.org...
irc#hadoop

People

Translate

site design / logo © 2022 Grokbase