Eventual Consistency — Concept Check
Questions on Eventual Consistency. Distributed systems that reject strict ACID guarantees accept that replicas converge to the same value given enough time; design UIs and workflows around this reality.
Questions in this quiz
7 questions on Eventual Consistency — Concept Check. Work through them here, then start the quiz to answer them and see your score.
1.A user places an order and immediately checks their order history, but the new order isn't visible. What is likely happening?
- AThe database is down, causing the order to be invisible.
- BThe read model hasn't caught up yet due to eventual consistency.
- CThe order is visible only after payment confirmation.
- DThe order wasn't processed due to a system error.
2.In a distributed system using eventual consistency, what should you do if an event arrives out-of-order?
- AIgnore the event as it's already outdated.
- BDiscard the event to avoid data corruption.
- CProcess the event immediately to maintain consistency.
- DUse idempotent consumers to handle out-of-order events gracefully.
3.After placing an order, the UI immediately shows the order in the list. What design pattern is this?
- AOptimistic UI
- BSynchronous UI
- CPessimistic UI
- DReactive UI
4.A service in your microservices architecture is experiencing slow updates. What could be a reason related to eventual consistency?
- AThe service is using strong consistency models.
- BThe service is using synchronous communication.
- CThe service has a large consistency window due to slow consumers.
- DThe service is not partition-tolerant.
5.What is a strategy to handle distributed failures in a system using eventual consistency?
- AAvoid intermediate states to simplify design.
- BImplement a Saga pattern with compensating transactions.
- CRely on strong consistency guarantees.
- DUse synchronous transactions to ensure consistency.
6.In a microservices system, why might an order remain in 'PAYMENT_PENDING' state longer than expected?
- AThe payment service is experiencing delays, visible due to eventual consistency.
- BThe order was cancelled automatically.
- CThe order service is down.
- DThe user hasn't confirmed the order yet.
7.What is the CAP theorem trade-off made by most microservices systems?
- AThey ensure all three: Consistency, Availability, and Partition Tolerance.
- BThey choose Availability and Partition Tolerance, sacrificing Consistency.
- CThey choose Consistency and Partition Tolerance, sacrificing Availability.
- DThey choose Consistency and Availability, sacrificing Partition Tolerance.