skip to content

As an architect, when would you choose Apache Pulsar over Kafka, and when does Kafka's partition-centric design remain the better choice?

level: principalimportance: should knowfreq 50%

answer

  1. Pulsar: queue+stream, tenancy, geo-repl, elastic compute/storage, huge topics
  2. Kafka: ecosystem (Connect/Streams/ksqlDB/SR), simpler ops, talent
  3. elasticity != raw throughput ceiling
  4. KIP-405 narrows storage gap
  5. decide on requirements, ≥2 differentiators

basics

~20 s

Choose Pulsar when you need unified queue+stream semantics, native multi-tenancy, built-in geo-replication, or independent compute/storage scaling and huge topic counts. Stick with Kafka for its mature ecosystem, simpler ops, and when partition-based streaming with a rich connector/stream-processing toolchain fits.

solid answer

~40 s

Pulsar wins when its differentiators map to real requirements: you want one platform to serve both work-queue (Shared/Key_Shared) and streaming (Exclusive/Failover) workloads; you must host many tenants on one cluster with per-namespace quotas/auth; you need built-in active-active geo-replication; you want stateless brokers for instant failover and independent scaling of compute (brokers) versus storage (bookies); or you have very large topics/backlogs that a single broker disk can't hold. Kafka remains the better default when ecosystem maturity dominates — Kafka Connect, Kafka Streams, ksqlDB, Schema Registry, exactly-once with transactions, and deep tooling/talent — and when a single tier is simpler to operate than Pulsar's brokers + bookies + metadata store. For most ordered, partitioned event-streaming with established teams, Kafka's operational simplicity and ecosystem usually outweigh Pulsar's architectural elegance.

go deeper

for a junior

Know the headline trade-off: Pulsar for unified queue+stream/tenancy/geo-repl; Kafka for ecosystem and simpler ops.

for a middle

List the concrete Pulsar differentiators and the concrete Kafka ecosystem strengths and match them to requirements.

for a senior

Reason about operational surface, KIP-405 vs BookKeeper, migration cost, and elasticity vs raw throughput.

for a principal

Drive the decision from requirements (need ≥2 differentiators), quantify operational/talent risk, and own the migration and platform-consolidation trade-off.

**Decide from requirements, not aesthetics.** Both are durable, ordered, partitioned, replicated pub/sub systems. The choice turns on which of Pulsar's architectural features you actually need, weighed against Kafka's ecosystem and operational maturity. **Lean Pulsar when:** 1. **You need queue AND stream semantics in one system.** Pulsar's subscription modes (Exclusive/Failover = ordered stream; Shared = work queue; Key_Shared = per-key-ordered fan-out) plus per-message ack, negative-ack, delayed messages, and native dead-letter topics cover use cases that would otherwise require Kafka *plus* RabbitMQ/SQS. Consolidating two systems into one is a real operational win. 2. **Native multi-tenancy.** A platform team hosting many internal/external tenants benefits from tenant→namespace→topic isolation with per-namespace quotas, auth, and retention, instead of bolting tenancy onto Kafka via naming conventions, ACLs, quotas, or one-cluster-per-tenant. 3. **Built-in geo-replication**, especially active-active, without operating MirrorMaker 2 as a separate Connect deployment. 4. **Independent compute/storage scaling and elastic ops.** Stateless brokers give near-instant failover and let you scale serving (brokers) separately from storage (bookies). Useful for spiky workloads and fast autoscaling. 5. **Very large topics / long retention as a stream store.** Segment-centric storage stripes a topic across all bookies, so topics can exceed a single node's disk and storage grows copy-free. Combined with **tiered storage** to object stores, Pulsar is attractive as a long-retention event store. 6. **High topic count** with frequent create/teardown — Pulsar handles large numbers of topics well. **Lean Kafka when:** 1. **Ecosystem and tooling dominate.** Kafka Connect's huge connector catalog, Kafka Streams and ksqlDB for stream processing, the de-facto Schema Registry, mature exactly-once **transactions**, and broad monitoring/ops tooling. Pulsar has analogues (Pulsar IO, Pulsar Functions, its own schema registry) but a smaller ecosystem and talent pool. 2. **Operational simplicity / team familiarity.** Kafka is one tier of brokers (now with KRaft removing ZooKeeper). Pulsar is brokers + bookies + a metadata store (+ optional function workers) — more components, more failure modes, more expertise required. For a small team, that overhead can outweigh the architectural benefits. 3. **Standard partitioned streaming is the whole job.** If you need ordered, partitioned event streams consumed by groups, and don't need work-queue fan-out, native tenancy, or built-in geo-repl, Kafka does it with less to operate. 4. **Hiring/community.** Far more engineers know Kafka; vendor support and managed offerings (MSK, Confluent Cloud) are ubiquitous. **Things people get wrong.** - *'Pulsar is always more scalable.'* It's more *elastic* (copy-free scaling, stateless brokers), but Kafka scales to enormous throughput too; the difference is operational elasticity and storage disaggregation, not a raw throughput ceiling. - *'Pulsar replaces RabbitMQ for free.'* Shared mode gives queue semantics, but you still operate BookKeeper and accept its complexity. - *'Kafka can't do long retention.'* With tiered storage (KIP-405) Kafka offloads cold segments to object storage, narrowing Pulsar's storage advantage — though the hot path stays broker-coupled. - *'Migration is trivial.'* Client protocols differ; Pulsar offers a Kafka-protocol handler (KoP) and Kafka has no Pulsar mode, so cross-migration is real engineering. **A pragmatic default.** For a typical org doing event streaming with existing Kafka skills and connector needs, Kafka is the lower-risk default. Choose Pulsar deliberately when two or more of its differentiators (queue+stream unification, multi-tenancy, geo-replication, compute/storage disaggregation, very large topics) are first-order requirements — that's when its added operational surface pays for itself.

  • Name two Pulsar differentiators that, if both required, justify choosing it over Kafka.
    Examples: native multi-tenancy (tenant/namespace isolation with quotas/auth) plus unified queue+stream subscription modes; or built-in active-active geo-replication plus independent compute/storage scaling via stateless brokers and BookKeeper. Any two first-order requirements that Kafka only approximates with add-ons.
  • Which Kafka capabilities most often keep teams on Kafka despite Pulsar's architecture?
    The ecosystem: Kafka Connect's connector catalog, Kafka Streams/ksqlDB, the de-facto Schema Registry, mature exactly-once transactions, ubiquitous managed services (MSK, Confluent Cloud), and a far larger talent pool — plus simpler single-tier ops, especially with KRaft removing ZooKeeper.
  • Does Kafka tiered storage eliminate Pulsar's storage advantage?
    It narrows it: KIP-405 offloads cold/closed segments to object storage, enabling cheap long retention. But the active segment and serving stay on the broker's local disk, so it isn't the full compute/storage disaggregation Pulsar provides via BookKeeper.

saying these in an interview costs you the question

  • Claiming Pulsar is strictly superior / always more scalable
  • Saying Kafka can't do long retention or geo-replication at all
  • Ignoring Pulsar's extra operational surface (bookies + metadata store)
  • Treating a Kafka↔Pulsar migration as a config change rather than real engineering
  • Recommending Pulsar without naming which differentiators the workload needs

context