Distributed write operations - SAGA pattern
3 important questions on Distributed write operations - SAGA pattern
3 goals of the SAGA pattern
- We want to ensure data consistency for our system of services.
- we need to avoid distributed transactions to ensure scalability.
- we want to minimize the coupling between our services so that failures don’t cascade and that we can implement and deploy them independently of each other.
What is a SAGA pattern ?
split a distributed write operation into multiple, independent steps. Each step gets handled by a different service. Within each service, you can use a standard ACID transaction to ensure data consistency.
only rely on idempotent operations and provide compensation operations for each possible failure
SAGA Transaction characteristics
doesn’t provide ACID characteristics
only ensures atomicity, consistency, and durabilitymultiple SAGAs are not isolated from each other
The question on the page originate from the summary of the following study material:
- A unique study and practice tool
- Never study anything twice again
- Get the grades you hope for
- 100% sure, 100% understanding