Placing an order calls three services in sequence — Payment, Inventory, and Shipping. If Shipping fails after Payment and Inventory already succeeded, the customer is charged for an order that never ships and stock is wrongly reserved. There is no rollback. Make the transaction consistent across services.
A saga coordinates a transaction spanning multiple services without a distributed 2PC lock. An orchestrator drives each local step and, if a later step fails, invokes compensating actions to undo the earlier ones. This keeps the system consistent under partial failure. The trade-off is complexity and eventual (not atomic) consistency between steps.
Evaluation criteria and weights will be revealed after you submit your solution. This ensures a fair assessment of your design skills.
Draw your architecture diagram, explain your design decisions, and get AI-powered feedback.
For the best experience, design challenges on a desktop or tablet — drawing the architecture on a phone is hard.