0
0
LLDsystem_design~20 mins

Event-driven design in LLD - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Event-driven Design Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
What is the primary benefit of using event-driven design in a distributed system?

Consider a distributed system where components communicate asynchronously. What is the main advantage of using event-driven design in such a system?

AIt eliminates the need for any message queues or brokers.
BIt forces all components to wait for each other, ensuring strict synchronization.
CIt allows components to operate independently and react to events without tight coupling.
DIt requires components to share a common database for communication.
Attempts:
2 left
💡 Hint

Think about how components communicate and depend on each other in event-driven systems.

Architecture
intermediate
2:00remaining
Which component is essential in an event-driven architecture to decouple event producers and consumers?

In an event-driven architecture, what component helps to decouple the event producers from the event consumers?

AEvent Broker or Message Queue
BDirect API calls between producer and consumer
CShared Database Table
DSynchronous HTTP Requests
Attempts:
2 left
💡 Hint

Think about how events are passed without direct connection between components.

scaling
advanced
2:00remaining
How does event-driven design improve system scalability compared to synchronous request-response design?

Compare event-driven design with synchronous request-response design. How does event-driven design help improve scalability?

ABy forcing all components to wait for responses before continuing, ensuring consistency.
BBy allowing components to process events asynchronously, reducing blocking and enabling parallelism.
CBy requiring all events to be processed in a single thread to avoid race conditions.
DBy eliminating the need for load balancers in the system.
Attempts:
2 left
💡 Hint

Think about how asynchronous processing affects resource usage and throughput.

tradeoff
advanced
2:00remaining
What is a common tradeoff when using event-driven design regarding data consistency?

Event-driven systems often sacrifice something to gain scalability and decoupling. What is a common tradeoff related to data consistency?

AEventual consistency instead of immediate consistency across components.
BStrong consistency with immediate updates everywhere.
CNo need for data replication or synchronization.
DGuaranteed order of all events without delay.
Attempts:
2 left
💡 Hint

Consider how asynchronous event processing affects the timing of data updates.

estimation
expert
2:00remaining
Estimate the maximum event throughput for a system using a single event broker with 10 partitions, each handling 1000 events per second.

A system uses one event broker with 10 partitions. Each partition can handle 1000 events per second. What is the maximum total event throughput the system can handle?

A100 events per second
B100,000 events per second
C1,000 events per second
D10,000 events per second
Attempts:
2 left
💡 Hint

Multiply the number of partitions by the throughput per partition.