Distributed System
Orders, inventory, and payment run in different services. When a service or network fails, show exactly how far the order got.
Orders, inventory, and payment run in different services. When a service or network fails, show exactly how far the order got.
One user action spans independent runtime nodes.
The network splits one action into independent outcomes: After the order service sends an inventory request, inventory may have processed it, not received it, or processed it while the response was lost. Do not treat order-service success as proof that checkout completed; preserve the cross-service request identity and each result.
Return feedback to the same business operation: After an inventory timeout, use the request ID to determine what happened on both sides, then choose waiting, retrying, compensating, or informing the user. Verify a normal request and an unreachable-service request after the fix; these mechanisms improve judgment and recovery but do not remove network failure.
Online meeting transcription is also distributed: The recording service may have saved the audio while the transcription service returned nothing after a network timeout. Record the saved-audio and transcription states under the same meeting ID so the system can retry transcription instead of asking the user to record again.
Inspect the order and inventory services in the checkout flow. Keep one request ID across the call, and record sent, received, success, failure, and timeout results separately. Simulate an unreachable inventory service and state the order status, retry behavior, and how duplicate stock deduction is prevented. Verify one normal order and one inventory-timeout case with observable results from each service.