Bird
0
0

You want to build a scalable order processing system using Kafka. Which approach best uses event-driven design to handle sudden spikes in orders?

hard📝 Application Q8 of 15
Kafka - Event-Driven Architecture
You want to build a scalable order processing system using Kafka. Which approach best uses event-driven design to handle sudden spikes in orders?
AUse a single producer and consumer to avoid complexity
BProcess orders synchronously in a single application without Kafka
CUse multiple producers sending orders to a Kafka topic and multiple consumers processing orders independently
DStore orders in a database and poll it periodically instead of Kafka
Step-by-Step Solution
Solution:
  1. Step 1: Identify event-driven scaling principles

    Multiple producers and consumers allow parallel processing and load distribution.
  2. Step 2: Evaluate options for handling spikes

    Independent consumers can scale out to handle more orders during spikes.
  3. Final Answer:

    Use multiple producers sending orders to a Kafka topic and multiple consumers processing orders independently -> Option C
  4. Quick Check:

    Parallel producers and consumers = scalable spikes [OK]
Quick Trick: Multiple producers and consumers handle spikes best [OK]
Common Mistakes:
  • Using single consumer limits scalability
  • Avoiding Kafka loses event-driven benefits
  • Polling database is less efficient than Kafka

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kafka Quizzes