Choosing a Communication Mechanism
Orders needs to know whether Inventory has stock before answering the customer. That is a service call. After an order is accepted, other services can react to what happened through an event.
Choose by the result you need
- One answer now: Service calls.
- A sequence of answers: Streaming patterns.
- A reaction later: Events.
- A workflow that survives failure: Sagas and compensations.
Calls couple latency and availability. Events add delivery, ordering and idempotency concerns. Neither makes a multi-service operation atomic.
Go deeper
Compare the full examples and failure trade-offs.
Find a section from the full guide
The detailed material is preserved on a separate page. Earlier section links still work here.