Messaging, Queues & StreamsIntermediate15 min read1 questions

Message Queues vs Event Streams

Queues and logs look similar and behave completely differently. Which to reach for, how backpressure actually works, and what to do with messages that will never succeed.

Covers: Queue vs log semantics, decoupling, backpressure, dead-letter queues, ordering, fan-out, when not to use a queue

Adding a queue is the standard answer to “this is too slow” - and it is often right. But a queue is not a magic latency eraser: it converts a slow synchronous operation into a fast one plus a promise, and that promise introduces ordering questions, duplicate delivery, and a brand new failure mode called the queue is 4 million messages deep.

Filter
0/1 mastered
IntermediatequeuekafkamessagingAsked at Amazon, Uber

30-second answer

A queue holds work: a message is delivered to one consumer, acknowledged, and deleted. It is a job dispatcher, and it scales by adding competing consumers. A log holds an ordered, durable, replayable record: messages are appended and retained for a configured period, and each consumer group tracks its own offset independently. Many groups can read the same data without affecting one another, and a new consumer can replay history from the beginning. Choose a queue for task distribution, and a log when several independent consumers need the same events, or when replay matters.

Showing 1 of 1 questions for message-queues-and-event-streams.

Check your understanding

3 questions · no sign-up, nothing stored

0/3 answered
Question 1

1.Three teams each need to react to every OrderPlaced event. Queue or log?

Question 2

2.Which is the most meaningful alert for an async pipeline?

Question 3

3.Producers publish 5,000/s; consumers process 4,000/s. What happens?