码迷,mamicode.com
首页 > Web开发 > 详细

flume配置参考

时间:2015-06-17 13:31:56      阅读:219      评论:0      收藏:0      [点我收藏+]

标签:flume   source   channel   sink   intercepter   

1 redis source,memory channel,json intercepter and file_roll sink配置例子

agent.sources = redis redis1
agent.channels = memory
agent.sinks = fileSink


agent.sources.redis.type = com.flumeng.plugins.source.RedisLPopSource
agent.sources.redis.host = 192.168.121.128
agent.sources.redis.port = 6379
agent.sources.redis.eventNamePrefix = event
agent.sources.redis.timeout = 3000
agent.sources.redis.charset = utf-8
agent.sources.redis.interceptors = i1
agent.sources.redis.interceptors.i1.type = com.flumeng.plugins.source.JSONInterceptor$Builder


agent.sources.redis1.type = com.flumeng.plugins.source.RedisLRangeSource
agent.sources.redis1.host = 192.168.121.128
agent.sources.redis1.port = 6379
agent.sources.redis1.eventNamePrefix = event
agent.sources.redis1.timeout = 3000
agent.sources.redis1.charset = utf-8
agent.sources.redis1.eventbatchSize = 2000
agent.sources.redis1.interceptors = i2
agent.sources.redis1.interceptors.i2.type = com.flumeng.plugins.source.JSONInterceptor$Builder


agent.channels.memory.type = memory
agent.channels.memory.capacity = 1000000
agent.channels.memory.transactionCapacity = 100000


agent.sinks.fileSink.type = file_roll
agent.sinks.fileSink.channel = memory
agent.sinks.fileSink.sink.directory = /mnt/hgfs/share/result/
agent.sinks.fileSink.sink.rollInterval = 0
agent.sinks.fileSink.batchSize=500


agent.sources.redis.channels = memory
agent.sources.redis1.channels = memory


2 redis source,memory channel,json intercepter and avro sink配置例子

agent.sources = redis redis1
agent.channels = memory
agent.sinks = fileSink


agent.sources.redis.type = com.flumeng.plugins.source.RedisLPopSource
agent.sources.redis.host = 192.168.121.128
agent.sources.redis.port = 6379
agent.sources.redis.eventNamePrefix = event
agent.sources.redis.timeout = 3000
agent.sources.redis.charset = utf-8
agent.sources.redis.interceptors = i1
agent.sources.redis.interceptors.i1.type = com.flumeng.plugins.source.JSONInterceptor$Builder


agent.sources.redis1.type = com.flumeng.plugins.source.RedisLRangeSource
agent.sources.redis1.host = 192.168.121.128
agent.sources.redis1.port = 6379
agent.sources.redis1.eventNamePrefix = event
agent.sources.redis1.timeout = 3000
agent.sources.redis1.charset = utf-8
agent.sources.redis1.eventbatchSize = 2000
agent.sources.redis1.interceptors = i2
agent.sources.redis1.interceptors.i2.type = com.flumeng.plugins.source.JSONInterceptor$Builder


agent.channels.memory.type = memory
agent.channels.memory.capacity = 1000000
agent.channels.memory.transactionCapacity = 100000


agent.sinks.fileSink.type = file_roll
agent.sinks.fileSink.channel = memory
agent.sinks.fileSink.sink.directory = /mnt/hgfs/share/result/
agent.sinks.fileSink.sink.rollInterval = 0
agent.sinks.fileSink.batchSize=500


agent.sources.redis.channels = memory
agent.sources.redis1.channels = memory

flume配置参考

标签:flume   source   channel   sink   intercepter   

原文地址:http://blog.csdn.net/hi_1234567/article/details/46532117

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!