Phase 15 · Message Queues & Event-Driven Architecture
TopicsPub/Sub vs Queue
Part of the Backend Developer Roadmap.
Summary
Pub/sub broadcasts a message to all current subscribers and loses it if no one's listening; a queue holds a message until exactly one consumer processes it — different guarantees for different needs.
How to Learn This
- 1Identify which pattern fits a real scenario: broadcasting a live update vs processing a background job.
- 2Learn that a 'topic' in Kafka behaves more like a durable, replayable pub/sub than a simple queue.
- 3Understand why queues suit 'do this work exactly once' and pub/sub suits 'notify everyone currently listening'.
More topics in Message Queues & Event-Driven Architecture
Stuck on this topic? Ask an Insider
Get 1:1 guidance from people who've walked this exact path — free on the InsideEdge app.