advanced
Distributed Transactions with Sagas
Design a choreography-based Saga pattern for an e-commerce order processing system.
📝 Contenu du Prompt
Design a choreography-based Saga pattern to manage distributed transactions for an e-commerce platform consisting of Order Service, Payment Service, Inventory Service, and Shipping Service. Define the compensating transactions required for each service in case of a failure (e.g., payment timeout). Provide a sequence diagram illustrating the happy path and a rollback path triggered by an inventory shortage.