InputFormat有两个抽象方法:

getSplits     createRecordReader
 
InputSplits 将数据按照Split进行切分,一个Split分给一个task执行。
RecordReader 在Task中将Split按照key value进行切分,每个RecordReader切分的数据都给map方法执行一遍。
 
RecordReader三个抽象方法:
initialize     用来seek位置等
getCurrentKey getCurrentValue   map读取key value
nextKeyValue     生成key value
getProgress
close
 
OutputFormat     RecordWriter
 
OutputFormat抽象方法
checkOutputSpecs
getRecordWriter
 
OutputCommitter做繁重的工作,如create目录,rename,close等 

Hadoop InputFormat OutputFormat的更多相关文章

  1. [Hadoop] - 自定义Mapreduce InputFormat&OutputFormat

    在MR程序的开发过程中,经常会遇到输入数据不是HDFS或者数据输出目的地不是HDFS的,MapReduce的设计已经考虑到这种情况,它为我们提供了两个组建,只需要我们自定义适合的InputFormat ...

  2. Hadoop InputFormat详解

    InputFormat是MapReduce编程模型包括5个可编程组件之一,其余4个是Mapper.Partitioner.Reducer和OutputFormat. 新版Hadoop InputFor ...

  3. Hadoop InputFormat浅析

    本文转载:http://hi.baidu.com/_kouu/item/dc8d727b530f40346dc37cd1 在执行一个Job的时候,Hadoop会将输入数据划分成N个Split,然后启动 ...

  4. Hadoop InputFormat

    Hadoop可以处理不同数据格式(数据源)的数据,从文本文件到(非)关系型数据库,这很大程度上得益于Hadoop InputFormat的可扩展性设计,InputFormat层次结构图如下:  

  5. Hadoop MapReduce InputFormat/OutputFormat

    InputFormat import java.io.IOException; import java.util.List; /** * InputFormat describes the input ...

  6. InputFormat,OutputFormat,InputSplit,RecordRead(一些常见面试题),使用yum安装64位Mysql

    列举出hadoop常用的一些InputFormat InputFormat是用来对我们的输入数据进行格式化的.TextInputFormat是默认的. InputFormat有哪些类型? DBInpu ...

  7. hadoop中OutputFormat 接口的设计与实现

    OutputFormat 主要用于描述输出数据的格式,它能够将用户提供的 key/value 对写入特定格式的文件中. 本文将介绍 Hadoop 如何设计 OutputFormat 接口 , 以及一些 ...

  8. Hadoop InputFormat 输入文件分片

    1. Mapper 与 Reducer 数量 对于一个默认的MapReduce Job 来说,map任务的数量等于输入文件被划分成的分块数,这个取决于输入文件的大小以及文件块的大小(如果此文件在 HD ...

  9. hadoop InputFormat 类别

    FileInputFormat是所有使用文件作为数据源的InputFormat的积累.它提供两个功能:一个是定义哪些文件包含在一个作业的输入中:一个为输入文件生成分片的实现.自动将作业分块 作业分块大 ...

随机推荐

  1. bootstrap API地址

    http://wenzhixin.net.cn/p/bootstrap-table/docs/examples.html#pagination-table

  2. [转]Ubuntu下配置NFS服务

    [转]Ubuntu下配置NFS服务  http://blog.163.com/liu8821031%40126/blog/static/111782570200921021253516/ Table ...

  3. iOS 进阶 第十六天(0419)

    0419 任何view默认不支持多点触控,有一个属性设置Multiple Touch,设置为Yes即可支持多点触控 触摸移动一个view,让view也跟着动代码 关于触摸的一些解释: 注意:touch ...

  4. 软件工程随堂作业--随机产生30到四则运算(c语言)

    #include "stdio.h" #include "math.h" #include "stdlib.h" #include" ...

  5. 团队项目--“我爱淘”校园二手书店 NABC分析

    本项目的特点之一:可查询功能 NABC分析: N(Need):方便校园里的学生查找自己需要的二手书籍,免了同学想买二手书还得跑到阿姨那里去看. A(Approach):将学生的信息和书籍的信息都存放在 ...

  6. html5之canvas练习

    代码地址:github.com/peng666/blogs 在线地址:http://peng666.github.io/blogs/

  7. 使用WatchService监控指定目录内的文件的改动

    package coin; import java.io.IOException; import java.nio.file.FileSystems; import java.nio.file.Pat ...

  8. 临时文档9--dfs

    #include<iostream> #include<stdio.h> #include<math.h> #include<string.h> usi ...

  9. Posix线程编程指南(2) 线程私有数据

    概念及作用 在单线程程序中,我们经常要用到"全局变量"以实现多个函数间共享数据.在多线程环境下,由于数据空间是共享的,因此全局变量也为所有线程所共有.但有时应用程序设计中有必要提供 ...

  10. 【POJ】【2601】Simple calculations

    推公式/二分法 好题! 题解:http://blog.csdn.net/zck921031/article/details/7690288 这题明显是一个方程组……可以推公式推出来…… 然而这太繁琐了 ...