Apache Pulsar is the third major option in the durable-streaming space, alongside Kafka and the AMQP/JetStream world. Where Kafka is a tightly-coupled broker-plus-storage model, Pulsar splits the two: stateless brokers route traffic, a separate storage layer (Apache BookKeeper) holds the bytes. This article is the operator-grade overview we use with clients evaluating Pulsar — the architecture in honest detail, the operational model, native geo-replication, tenancy, and the decision criteria for picking Pulsar versus Kafka or a quorum-queue RabbitMQ.
How to verify
Pulsar’s standalone install runs broker, bookie, and ZooKeeper in one process for evaluation; production splits them. Confirm what is present:
ps -ef | grep -E 'pulsar|bookkeeper|zookeeper'
ss -ltnp | grep -E ':(2181|6650|8080|3181)\b'
curl -s http://localhost:8080/admin/v2/clusters | python3 -m json.tool
curl -s http://localhost:8080/admin/v2/brokers/standalone | head -20
Standard ports: 2181 (ZooKeeper), 3181 (BookKeeper), 6650 (Pulsar binary protocol), 8080 (Pulsar admin HTTP).
What’s happening
Pulsar has four moving parts:
- Broker — stateless service that accepts produces, fans out consumes, holds no persistent data of its own. Brokers are the routing tier. Adding a broker scales connection handling, not storage.
- Bookie (BookKeeper) — the storage tier. A bookie is a node in a BookKeeper ensemble; ensembles store ledgers (segments of a topic) across configurable numbers of bookies (
ensemble size,write quorum,ack quorum). Adding a bookie scales storage and write throughput. - ZooKeeper — metadata for both brokers and bookies. (A move to a self-hosted metadata store similar to KRaft is in progress as
Oxiabut ZK is still the production default at the time of writing.) - Proxy (optional) — an Envoy-style fronting tier that terminates client connections and forwards to brokers; useful when brokers should not be directly client-reachable.
The separation of compute and storage is the structural difference from Kafka. In Kafka, a broker is both the network endpoint and the disk holding the partition; losing a broker means rebalancing the partitions it owned. In Pulsar, a broker only owns a topic temporarily (the “owner broker” pattern); if it dies, another broker takes ownership and the ledgers in BookKeeper are unaffected. This makes broker failover faster and topic-rebalance painless. The trade-off is more moving parts to operate — three tiers instead of one.
Tenants and namespaces. Pulsar is multi-tenant by design. A topic full name is persistent://tenant/namespace/topic (tenant-a/orders/created). Quotas, retention, schema validation, geo-replication policies are namespace-level. This is heavier than Kafka’s flat topic namespace but pays off when you have many teams sharing a cluster.
Subscription modes. Pulsar abstracts over both Kafka-style streaming and AMQP-style queueing:
Exclusive— one consumer per subscription. Kafka-like for a single reader.Failover— one active consumer, others standby. HA for single-reader workflows.Shared— round-robin across consumers in the subscription. Queue semantics.Key_Shared— keyed sharding within a subscription. Per-key ordering with horizontal scale.
This subscription-mode flexibility is unique among the big three brokers and is the single best technical reason to pick Pulsar.
Geo-replication. A namespace can have N replicated clusters listed; brokers in each cluster forward produces to peer clusters using the binary protocol. No external tool, no separate config file, no MirrorMaker. For multi-region designs where data must converge across two or more clusters, this is a meaningful operational simplification.
When to pick Pulsar
- Multi-tenant requirements. If you are building a platform that serves multiple teams or customers from one cluster, Pulsar’s tenants/namespaces beat Kafka’s flat topics and ACL-based scoping.
- Mixed streaming and queueing. If half your workload is event-sourcing (streaming) and the other half is task queues (queueing), one Pulsar cluster covers both. Two separate brokers covers it too, but with more sprawl.
- Native geo-replication. If you have a two-region active-active requirement and would otherwise stand up Kafka MirrorMaker 2 or a custom solution, Pulsar’s built-in geo-rep is materially simpler.
- Topic count in the millions. Pulsar’s per-topic overhead is lower than Kafka’s at the metadata layer; very large topic catalogs are kinder on a Pulsar cluster.
When not to pick Pulsar
- Small team, single-tenant, no geo-rep need. The extra operational surface (brokers + bookies + ZK) is not worth it. Kafka or RabbitMQ are easier to operate at that scale.
- Heavy stream-processing ecosystem. Kafka Streams, ksqlDB, Flink Kafka connectors are more mature than the Pulsar equivalents. Pulsar Functions exist but the ecosystem is smaller.
- Team already runs Kafka well. Migrating away from a working Kafka cluster solely for tenancy or geo-rep features is rarely worth the disruption; layer tooling on Kafka first.
The procedure (evaluation install)
For a production cluster, plan separate machines for brokers, bookies, and ZK; for evaluation:
-
Download and start standalone:
PULSAR_VER=3.2.2 curl -fsSL "https://archive.apache.org/dist/pulsar/pulsar-${PULSAR_VER}/apache-pulsar-${PULSAR_VER}-bin.tar.gz" \ | tar -xz -C /opt sudo mv /opt/apache-pulsar-${PULSAR_VER} /opt/pulsar cd /opt/pulsar bin/pulsar standalone -
Create a tenant and namespace:
bin/pulsar-admin tenants create tenant-a bin/pulsar-admin namespaces create tenant-a/orders bin/pulsar-admin namespaces set-retention tenant-a/orders --size 10G --time 7d -
Produce and consume:
bin/pulsar-client produce persistent://tenant-a/orders/created \ --num-produce 100 --messages "order-1,order-2,order-3" bin/pulsar-client consume persistent://tenant-a/orders/created \ --subscription-name analytics --num-messages 0 --subscription-type Shared -
Inspect with the admin API:
bin/pulsar-admin topics stats persistent://tenant-a/orders/created bin/pulsar-admin topics subscriptions persistent://tenant-a/orders/created
Operational notes
- BookKeeper bookies have three on-disk components: journal (sequential write, fast disk), ledger (random read), and index. Production sizing puts journal on NVMe, ledgers on bulk storage.
- The ZooKeeper ensemble is the single weakest link of a production Pulsar deployment until Oxia replaces it; size and operate it accordingly.
- Pulsar uses two ports per broker (6650 binary, 8080 HTTP admin) — front them with separate load balancer rules if the proxy tier is not used.
- A namespace’s retention policy is what determines whether messages persist beyond acknowledgement; without retention, “acked = deleted” is the default.
- Geo-replication is asynchronous; cross-cluster lag is normal during WAN events and should be alerted on, not panicked over.
Stack Harbor evaluates and stands up Pulsar clusters for clients with multi-tenant or multi-region requirements that Kafka would solve only with bolted-on tooling. Where Pulsar is the right fit, we plan the broker/bookie/ZK topology, size storage to the actual write pattern, and operate it under the same playbook as the rest of the messaging tier. This is the work covered by our Managed Operations practice.