Interactive architecture advice
Sync vs Async Processing
Answer a few questions to explore a suggested pattern and its trade-offs. Each answer explains why it fits, what you gain and what to check before putting it into practice.
Synchronous processing finishes during the request. Asynchronous processing accepts work and completes it later. Match the flow to timeouts and what the caller actually needs.
01Your requirements
Include slow dependencies and busy periods when estimating duration, rather than only the typical case.
A completed result differs from confirmation that a job has been accepted.
Suggested pattern
Answer the questions to explore a starting pattern.
Architecture depends on workload, risk, team capability and constraints. Validate assumptions and evaluate a small proof of concept; this is a starting point for your design.
Turn this into a practical decision
- Measure typical and slow-case processing time.
- For a background job, define queued, running, succeeded and failed states.
- Give clients a status lookup, time limit and safe retry mechanism.