All topicsTopic 22 / 24
Intermediate 1 minute
Message Queues
A message queue stores work until a consumer is ready to process it. Producers and consumers do not need to run at the same speed or at the same time. Queues absorb bursts, isolate failures, and make background processing easier to scale. Reliable systems define acknowledgement, retry, visibility timeout, ordering, and what happens to messages that repeatedly fail.
Key idea
A queue turns a direct dependency into durable work waiting to be handled.
See it in one picture
Follow the arrowsProducer
Queue
Worker 1
Worker 2
Work waits safely
Real-world example
When a user uploads a photo, the API can place an image-processing message on a queue and respond quickly. Worker processes resize images later, retrying temporary failures without blocking the upload.
Quick check