You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

MirrorMaker 2双向同步场景咨询:每个需复制主题是否在链路两端各需6个系统主题?主题爆炸风险探讨

MirrorMaker 2 System Topics: Busting the "Topic Explosion" Myth

Great question—this is a super common concern when setting up bidirectional Kafka syncs with MirrorMaker 2 (MM2), so let’s break this down clearly to ease your worries.

First, let’s correct a critical misunderstanding: MM2 does NOT create 6 system topics per replicated business topic. Instead, system topics are tied to replication links (the sync relationship between a source and target cluster), not individual business topics. That’s the key detail that prevents "topic explosion."

What System Topics Does MM2 Actually Create?

For a single unidirectional replication link (e.g., Cluster A → Cluster B), MM2 generates a fixed set of system topics (typically 5-6, depending on your config) on the target cluster. These include:

  • mm2-[source-cluster]-to-[target-cluster]-heartbeats: Tracks liveness of MM2 workers
  • mm2-[source-cluster]-to-[target-cluster]-checkpoints: Stores offset checkpoints for replicated topics
  • mm2-[source-cluster]-to-[target-cluster]-offsets: Maps source topic offsets to target offsets
  • mm2-[source-cluster]-to-[target-cluster]-status: Tracks replication task health and progress
  • mm2-[source-cluster]-to-[target-cluster]-configs: Stores dynamic configuration for the replication link
  • (Optional) mm2-[source-cluster]-to-[target-cluster]-topics: Used if you’re auto-discovering topics to replicate

Bidirectional Sync: How This Scales

Bidirectional sync is just two separate unidirectional links working in tandem: Cluster A → Cluster B, and Cluster B → Cluster A. Each link gets its own set of system topics:

  • On Cluster B, you’ll have the 5-6 system topics for the A→B link
  • On Cluster A, you’ll have the 5-6 system topics for the B→A link

The total number of system topics here is 10-12 across both clusters—no matter how many business topics you’re replicating. Even if you sync 1000+ business topics, you still only have these 10-12 system topics. That’s a night-and-day difference from the per-topic scenario you were worried about.

Quick Tips to Keep Things Clean

If you want to minimize clutter even further:

  • Customize the system topic prefix with the mm2.prefix config to group them neatly
  • Disable optional system topics if you don’t need them (e.g., turn off auto-discovery if you’re explicitly listing topics to sync)
  • Use Kafka’s built-in topic filtering tools to separate system topics from your business topics in monitoring UIs

内容的提问来源于stack exchange,提问作者teeboy

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.28 11:22:35