AMQP Consumers and Topology Practice
AMQP Consumers and Topology Practice
animation
amqp
protocols
messaging
Consumer topology checkpoint
Tip
Checkpoint: Consumer Topology
Checkpoint: Consumer Topology
You now know:
- Competing consumers share one queue so each message is handled once by one worker.
- Fan-out gives each consumer its own queue, so every consumer sees every event and broker memory grows with copies.
- Prefetch matters most for competing consumers because high prefetch lets one worker hold messages that other workers could process.
Routing questions
Knowledge Check
Question: What does an exchange do in AMQP?
TipAnswer
Routes messages to queues based on rules
Question: What’s the difference between * and # wildcards?
TipAnswer
* matches exactly one word; # matches zero or more words
Question: When would you use fanout exchange?
TipAnswer
When every subscriber needs to receive every message (like broadcast)
Pika setup practice
Factory routing checkpoint
Tip
Checkpoint: Factory Alert Routing
Checkpoint: Factory Alert Routing
You now know:
- A routing key hierarchy such as
alert.{severity}.{line}.{machine}lets teams subscribe by severity, line, or catch-all history without producer rewrites. - The worked example reduces broadcast delivery waste because broker-side pattern matching sends critical, warning, and info alerts only to the queues that need them.
- Alternate exchanges and dead-letter queues are the safety net when a message has no matching route.
Label the diagram
Label the Diagram
Order the steps
Order the Steps
Match the concepts
Match the Concepts
Technical boundaries. The Pika setup uses localhost, one topic exchange, and one routing key. It publishes a message but does not show queues, bindings, or consumers receiving and settling deliveries.