BTI Beyond The Interviews

System Design & Architecture · 9 sections

Message Queues

Kafka, RabbitMQ, and the messaging patterns behind event-driven systems.

Premium · preview 136 cards Updated 24 Oct 2026
Free to preview. The first 3 cards and the full outline are below — the rest of this sheet is part of the System Design bundle.

What's inside

Preview — first 3 of 136 cards

Queue vs topic

Queue: point-to-point, each message consumed once. Topic: pub/sub, multiple subscribers each get a copy. Kafka topics are partitioned logs; RabbitMQ queues are the default.

kafka-topics.sh --create --topic orders --partitions 6

Producer

Application that writes messages to a broker. Should handle retries, idempotency, and backpressure. Producers choose partition via key or round-robin.

producer.send(new ProducerRecord<>("orders", key, value))

Consumer

Application that reads and processes messages. Tracks progress via offsets/acks. Should be idempotent and handle rebalancing gracefully.

consumer.subscribe(List.of("orders"));
ConsumerRecords<K,V> r = consumer.poll(Duration.ofMillis(100));

133 more cards in this sheet

Unlock the System Design bundle — ₹399

One-time payment. Unlocks this sheet and 10 other sheets in the bundle, plus a typeset PDF of each.

Unlock the bundle See all bundles

Or get all 76 sheets for ₹999 — one payment, every future sheet included.