Apache Pulsar 中的主题复制

Topic replication in Apache Pulsar

replication in Pulsar 上的文档描述性不强。 我想知道复制的详细工作原理以及 persistence policies for a namespace 如何发挥作用。文档讨论了这些参数

bookkeeper-ack-quorom是否意味着,对客户端的确认被延迟,直到这个数量的博彩公司将条目写入磁盘?

bookkeeper-ensemblebookkeeper-write-quorum有什么区别?

假设我有 3 个 bookie,我希望命名空间中的主题驻留在每个 bookie 上,然后我将两个值都设置为 3?

Does bookkeeper-ack-quorom mean, that the ack to the client is delayed until this number of bookies have written the entry to disk?

没错。如果您的 ack-quorum 是 2,这意味着当发布成功时您将有 2 个有保证的消息副本。 在默认配置中,这意味着消息被写入磁盘并刷新(fsynced)到 2 台机器上的磁盘。

What is the difference between bookkeeper-ensemble and bookkeeper-write-quorum?

Ensemble 是用于分类帐的 bookie 数量。大多数情况下,这被配置为等于写仲裁。

设置 ensemble > write-quorum 将启用“在单个主题内跨多个博彩公司拆分条目。

例如,设置 e=5 w=2 a=2 将使得:

  • 每条消息写2份,我们等待2次acks
  • 消息在 5 个 bookies 中以循环方式条带化
  • 每个 bookie 都会有消息的子集 2/5
  • 每个赌徒都会有一个小write/read流量

基本上,它允许在不放松排序的情况下扩展单个分类帐的 IO。

Lets assume I have 3 bookies and I want topics in the namespace to reside on each of them, then I set both values to 3?

正确。尽管 ensemble 也表示为了接受写入而需要可用的最小 bookie 集。

如果你有 3 个 bookie 并设置 ensemble=3,你将无法容忍节点故障。