使用自定义配置镜像 kafka 主题作为独立应用程序 [英] Mirror kafka topics with custom configuration as a standalone application

查看:24
本文介绍了使用自定义配置镜像 kafka 主题作为独立应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想将一些主题从一个经纪人镜像到另一个经纪人.只是所有主题的一部分.有一个现有的 MirrorMaker 工具可以做到这一点.但我也想更改目标主题名称.此外,自定义消息处理程序 已经做到了.然而,它不符合我的需求.

I want to mirror some topics from one broker to another. Just part of all topics. There's an existed MirrorMaker tool for this. But I also want to change destination topic names. Also, Custom message handler already does it. Nevertheless, it doesn't fit my needs.

对我有几个要求:

  1. 镜像主题,可以为每个目标主题提供覆盖
  2. 动态检测新的源主题
  3. 将其作为独立应用程序(fe Java、Spring Boot)运行,而不是 CLI 方法

有人至少对其中之一有想法吗?

Does anybody have ideas at least for one of them?

推荐答案

据我所知,目前还没有任何工具可以完成您提到的所有事情.Confluent 的 Replicator 可能具有所有这些功能,但您必须为 Enterprise 许可证付费.详情请见:

As far as I know, there is no existing tool that does all the things you mention. Confluent's Replicator probably has all that functionality, but you'd have to pay for an Enterprise license. More details here:

https://www.confluent.io/connector/confluent-kafka-复制器/

我的建议是,如果您不想为 Confluent 许可证付费,则构建您自己的应用程序,该应用程序既消费又生产信息 Kafka.您将拥有完全控制权,您可以用 Java 编写它,您可以实现您想要的任何逻辑(自动检测新主题,在目标主题上动态更改名称等),并且您可以将其部署为普通的 JVM 应用程序最适合您的方式(普通 JVM、AWS EC2、Docker/Kubernetes 应用程序等)

My recommendation, if you don't want to pay for the Confluent license, is to build your own application that both consumes and produces info Kafka. You'd have full control, you can write it in Java, you can implement whatever logic you want (detect new topics automatically, change names dynamically on the destination topics, etc), and you can deploy it as a normal JVM application in whatever way suits you most (normal JVM, AWS EC2, Docker/Kubernetes app, etc)

这篇关于使用自定义配置镜像 kafka 主题作为独立应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆