Bird
0
0

Consider this scenario: A program sends messages to a Kafka topic, and multiple other programs read from it. What is the main benefit of this setup?

medium📝 Predict Output Q13 of 15
Kafka - Basics and Event Streaming
Consider this scenario: A program sends messages to a Kafka topic, and multiple other programs read from it. What is the main benefit of this setup?
AMessages are lost if one program fails
BMultiple programs can read the same messages independently
COnly one program can read messages at a time
DMessages are deleted immediately after being read
Step-by-Step Solution
Solution:
  1. Step 1: Understand Kafka's message consumption model

    Kafka allows multiple programs to read the same messages independently from a topic.
  2. Step 2: Analyze each option

    Messages are lost if one program fails is false because Kafka ensures message durability. Only one program can read messages at a time is incorrect because Kafka supports multiple consumers reading simultaneously. Messages are deleted immediately after being read is wrong because Kafka retains messages for a configured time, not deleting immediately after reading.
  3. Final Answer:

    Multiple programs can read the same messages independently -> Option B
  4. Quick Check:

    Kafka supports multiple independent readers [OK]
Quick Trick: Kafka lets many programs read same messages independently [OK]
Common Mistakes:
  • Believing messages disappear after one read
  • Thinking only one consumer can read at a time
  • Assuming message loss on failure

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kafka Quizzes