You are developing a serverless workflow using Azure Durable Functions. You need to ensure that the orchestrator function remains deterministic during execution. Which two actions must you perform to meet this requirement?
- Use the context's current UTC date-time property instead of using standard system date-time calls.Answer
- Create durable timers using the orchestration context rather than using thread sleep or task delay methods.Answer
- CGenerate unique request identifiers within the orchestrator using standard system GUID generation APIs.
- DRetrieve configuration settings directly from environment variables inside the orchestrator function.
Answer
To ensure the orchestrator function remains deterministic, you must use the context's current UTC date-time property instead of standard system date-time calls, and create durable timers using the orchestration context rather than thread sleep or task delay methods.
Orchestrator functions in Azure Durable Functions must be deterministic to ensure that replay execution behaves identically. Using the built-in context properties for current UTC date-time and creating durable timers instead of blocking threads ensures that the orchestration state remains consistent across execution replays.
Step-by-Step Solution
Key Concept
Orchestrator Function Determinism Constraints
Estimated Time:45s