flume_kafka联合使用

来源:互联网 发布:ubuntu启动mysql服务 编辑:程序博客网 时间:2024/05/21 07:57

在大数据的使用中常常将flume和kafka联合起来使用,实用的时候主要是一个配置的文件信息
配置文件信息如下

#agent sectionproducer.sources = sproducer.channels = cproducer.sinks = r#source section#producer.sources.s.type = seqproducer.sources.s.type = execproducer.sources.s.command =tail -F /tmp/test/a.txt producer.sources.s.channels = c# Each sink's type must be definedproducer.sinks.r.type = org.apache.flume.sink.kafka.KafkaSinkproducer.sinks.r.kafka.bootstrap.servers = localhost:9092producer.sinks.r.kafka.topic=testproducer.sinks.r.kafka.flumeBatchSize = 20producer.sinks.r.kafka.producer.acks = 1#Specify the channel the sink should useproducer.sinks.r.channel = c# Each channel's type is defined.producer.channels.c.type = memoryproducer.channels.c.capacity = 1000
0 0
原创粉丝点击