flume 中的 hdfs sink round 和roll
生活随笔
收集整理的這篇文章主要介紹了
flume 中的 hdfs sink round 和roll
小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
http://blog.csdn.net/kntao/article/details/49278239
http://flume.apache.org/FlumeUserGuide.html#exec-source
默認(rèn)的是是SequenceFile所以數(shù)據(jù)存在hdfs上通過命令查看的時(shí)候會(huì)是亂碼,如果此時(shí)需要修改filetype和writeFormat來(lái)修改
| hdfs.fileType | SequenceFile | File format: currently?SequenceFile,?DataStream?or?CompressedStream?(1)DataStream will not compress output file and please don’t set codeC (2)CompressedStream requires set hdfs.codeC with an available codeC |
其中DataStream是文本文件
a1.sinks.k1.type = hdfs a1.sinks.k1.channel = c1 a1.sinks.k1.hdfs.path = /maats/%{APPSTORE}/%Y%m%d/%H a1.sinks.k1.hdfs.filePrefix = events- a1.sinks.k1.hdfs.round = true a1.sinks.k1.hdfs.roundValue = 10 a1.sinks.k1.hdfs.roundUnit = minute a1.sinks.k1.hdfs.useLocalTimeStamp = true a1.sinks.k1.hdfs.fileType=DataStream a1.sinks.k1.hdfs.writeFormat=Text?
轉(zhuǎn)載于:https://www.cnblogs.com/rocky-AGE-24/p/6984313.html
總結(jié)
以上是生活随笔為你收集整理的flume 中的 hdfs sink round 和roll的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: ajax 赋值return
- 下一篇: 个人学习进度(第十六周)