0
0
Kafkadevops~20 mins

Kafka vs RabbitMQ vs Redis Pub/Sub - Practice Questions

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Messaging Systems Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
Primary Use Case Differences
Which of the following best describes the primary use case difference between Kafka, RabbitMQ, and Redis Pub/Sub?
AKafka is used for web hosting, RabbitMQ for file storage, Redis Pub/Sub for image processing.
BKafka is mainly for caching, RabbitMQ for database storage, Redis Pub/Sub for batch processing.
CKafka is designed for high-throughput event streaming, RabbitMQ for complex routing and message queuing, Redis Pub/Sub for lightweight real-time messaging without persistence.
DKafka is a relational database, RabbitMQ is a web server, Redis Pub/Sub is a programming language.
Attempts:
2 left
💡 Hint
Think about what each system is optimized to do in messaging and data handling.
Predict Output
intermediate
2:00remaining
Message Persistence Behavior
Given the following scenario, which system will retain messages if the consumer is offline and reconnects later?
Kafka
Scenario: A producer sends messages continuously. The consumer disconnects for 10 minutes and then reconnects.
AKafka will retain messages and deliver them when the consumer reconnects.
BRabbitMQ will not retain messages if the consumer is offline.
CRedis Pub/Sub will retain messages and deliver them when the consumer reconnects.
DNone of the systems retain messages for offline consumers.
Attempts:
2 left
💡 Hint
Consider which systems support message durability and replay.
🔧 Debug
advanced
2:00remaining
Unexpected Message Loss in Redis Pub/Sub
You implemented a Redis Pub/Sub system but notice that some messages are lost when subscribers are disconnected briefly. What is the root cause?
ARedis Pub/Sub uses a message broker that crashed.
BRedis Pub/Sub does not queue messages; if a subscriber is offline, it misses messages sent during that time.
CRedis Pub/Sub stores messages on disk but the disk is full.
DRedis Pub/Sub requires explicit message acknowledgments to prevent loss.
Attempts:
2 left
💡 Hint
Think about how Redis Pub/Sub handles message delivery and subscriber state.
📝 Syntax
advanced
2:00remaining
Kafka Consumer Group Configuration
Which Kafka consumer configuration option ensures that multiple consumers share the load of a topic's partitions?
ASetting 'auto.offset.reset' to 'latest'.
BSetting different 'group.id' values for each consumer.
CSetting 'enable.auto.commit' to false.
DSetting the same 'group.id' for all consumers to form a consumer group.
Attempts:
2 left
💡 Hint
Consumer groups allow load balancing across consumers.
🚀 Application
expert
3:00remaining
Choosing the Right System for Real-Time Analytics
You need to build a real-time analytics pipeline that processes millions of events per second with guaranteed message delivery and the ability to replay events for debugging. Which system is the best choice?
AKafka, because it supports high throughput, durability, and replayable event streams.
BRabbitMQ, because it is optimized for lightweight real-time messaging without persistence.
CRedis Pub/Sub, because it stores all messages and supports complex routing.
DNone of these systems can handle real-time analytics at scale.
Attempts:
2 left
💡 Hint
Consider throughput, durability, and replay features.