Bird
0
0

A developer reports that messages with the same key are sometimes reordered after a broker failure. What is the most probable reason?

medium📝 Debug Q7 of 15
Kafka - Topics and Partitions
A developer reports that messages with the same key are sometimes reordered after a broker failure. What is the most probable reason?
AKafka does not guarantee order under any failure.
BProducer retries with different sequence numbers causing duplicates and reordering.
CMessages with different keys are sent to the same partition.
DConsumer is committing offsets too frequently.
Step-by-Step Solution
Solution:
  1. Step 1: Understand failure impact on ordering

    Broker failure can cause producer retries which may reorder messages.
  2. Step 2: Identify producer retry behavior

    Retries with different sequence numbers can cause duplicates and reordering in the partition.
  3. Final Answer:

    Producer retries with different sequence numbers causing duplicates and reordering. -> Option B
  4. Quick Check:

    Producer retries cause reordering = B [OK]
Quick Trick: Retries can reorder messages if not handled properly [OK]
Common Mistakes:
  • Assuming Kafka never reorders messages
  • Confusing key assignment with partitioning
  • Blaming consumer offset commits

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kafka Quizzes