Reading and Writing Sequencefile using Hadoop 2.0 Apis

前端 未结 4 491
南旧
南旧 2020-12-14 08:50

I am looking for an example which is using the new API to read and write Sequence Files.

Effectively I need to know how to use these functions

 creat         


        
4条回答
  •  情深已故
    2020-12-14 09:31

    You need to set SequenceFile as input format

    job.setInputFormatClass(SequenceFileInputFormat.class);
    

    You will find an example of reading SeequnceFile form HDFS here.

提交回复
热议问题