我正在尝试将日志从主题转移到另一个主题。我需要使用Flume将Kafka连接到Kafka。在下面看看:
#
# Flume Conf
#
a1.sources = s1
a1.sinks = k1
a1.channels = c1
# Kafka Source
a1.sources.s1.type = org.apache.flume.source.kafka.KafkaSource
a1.sources.s1.kafka.bootstrap.servers = kafka:9092
a1.sources.s1.kafka.topics = apache
# Kafka Sink
a1.sinks.k1.type = org.apache.flume.sink.kafka.KafkaSink
a1.sinks.k1.kafka.bootstrap.servers = kafka:9092
# Use a channel which buffers events in memory
a1.channels.c1.type = memory
a1.channels.c1.capacity = 10000000
a1.channels.c1.transactionCapacity = 1000000
# Bind the source and sink to the channel
a1.sources.s1.channels = c1
a1.sinks.k1.channel = c1
接收器未创建。
答案 0 :(得分:1)
如果要将数据从一个Kafka群集复制到另一个群集,则有比Flume更好的方法,包括:
如果您想要真的肮脏的骇客,也可以do something with kafkacat
and nc
。
免责声明:我为Confluent工作。