You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@kafka.apache.org by Jake Mayward <ja...@outlook.com> on 2021/10/07 18:20:38 UTC

Mirror Maker 2: use prefix-less topic names?

Hi,

I have read a bit on MirrorMaker 2 via https://kafka.apache.org/documentation/#georeplication-overview, and I am curious whether I can enable replication with MirrorMaker 2 without having to prefix the topic with the cluster name. Reasoning behind this is that I would like the client to always use the same topic name, regardless of the cluster it is connected to.

Note: I have seen the https://github.com/apache/kafka/blob/trunk/connect/mirror-client/src/main/java/org/apache/kafka/connect/mirror/DefaultReplicationPolicy.java but it isn't obvious to me yet whether MM2 takes care of preventing a replication loop.

Thanks for any hints!
Jake

Re: Mirror Maker 2: use prefix-less topic names?

Posted by Ryanne Dolan <ry...@gmail.com>.
Jake, in the most recent Kafka 3.0 release you will find
IdentityReplicationPolicy, which does what you want. Just be careful that
you don't try to replicate the same topics in a loop.

Ryanne

On Thu, Oct 7, 2021, 1:31 PM Jake Mayward <ja...@outlook.com> wrote:

> Hi,
>
> I have read a bit on MirrorMaker 2 via
> https://kafka.apache.org/documentation/#georeplication-overview, and I am
> curious whether I can enable replication with MirrorMaker 2 without having
> to prefix the topic with the cluster name. Reasoning behind this is that I
> would like the client to always use the same topic name, regardless of the
> cluster it is connected to.
>
> Note: I have seen the
> https://github.com/apache/kafka/blob/trunk/connect/mirror-client/src/main/java/org/apache/kafka/connect/mirror/DefaultReplicationPolicy.java
> but it isn't obvious to me yet whether MM2 takes care of preventing a
> replication loop.
>
> Thanks for any hints!
> Jake
>

Re: Mirror Maker 2: use prefix-less topic names?

Posted by Men Lim <zu...@gmail.com>.
Nope. Mm2 has that prefix. I read that in 3.0, that prefix is going away.

On Thu, Oct 7, 2021 at 11:31 AM Jake Mayward <ja...@outlook.com>
wrote:

> Hi,
>
> I have read a bit on MirrorMaker 2 via
> https://kafka.apache.org/documentation/#georeplication-overview, and I am
> curious whether I can enable replication with MirrorMaker 2 without having
> to prefix the topic with the cluster name. Reasoning behind this is that I
> would like the client to always use the same topic name, regardless of the
> cluster it is connected to.
>
> Note: I have seen the
> https://github.com/apache/kafka/blob/trunk/connect/mirror-client/src/main/java/org/apache/kafka/connect/mirror/DefaultReplicationPolicy.java
> but it isn't obvious to me yet whether MM2 takes care of preventing a
> replication loop.
>
> Thanks for any hints!
> Jake
>