nerdexam
Microsoft

AZ-204 · Question #99

You are developing a complex workflow by using Azure Durable Functions. During testing you observe that the results of the workflow differ based on how many instances of the Azure Function are…

The correct answer is A. Ensure that all Orchestrator code is deterministic. To resolve issues where Durable Function workflow results differ across instances, all orchestrator code must be strictly deterministic.

Submitted by lars.no· Mar 30, 2026Develop Azure compute solutions

Question

You are developing a complex workflow by using Azure Durable Functions. During testing you observe that the results of the workflow differ based on how many instances of the Azure Function are running. You need to resolve the issue. What should you do?

Options

  • AEnsure that all Orchestrator code is deterministic.
  • BRead all state data from the durable function context
  • CConfigure the Azure Our able function to run on an App Service Plan with one instance.
  • DImplement the monitor pattern within the workflow.

How the community answered

(40 responses)
  • A
    75% (30)
  • B
    5% (2)
  • C
    8% (3)
  • D
    13% (5)

Why each option

To resolve issues where Durable Function workflow results differ across instances, all orchestrator code must be strictly deterministic.

AEnsure that all Orchestrator code is deterministic.Correct

Durable Functions orchestrator functions must always be deterministic, meaning they produce the same output given the same input, irrespective of execution instance or replay. Non-deterministic operations, like generating random numbers or getting current time directly, can cause inconsistent results across different function instances.

BRead all state data from the durable function context

While reading state data from the durable function context is correct practice, it does not inherently resolve non-deterministic logic within the orchestrator function itself.

CConfigure the Azure Our able function to run on an App Service Plan with one instance.

Configuring the function to run on a single App Service Plan instance might mask the problem but does not address the underlying non-deterministic nature of the orchestrator code, which is a fundamental design requirement.

DImplement the monitor pattern within the workflow.

Implementing the monitor pattern is a specific Durable Functions pattern, but it is not a solution for non-deterministic orchestrator code causing inconsistent results across instances.

Concept tested: Durable Functions orchestrator determinism

Source: https://learn.microsoft.com/en-us/azure/azure-functions/durable/durable-functions-orchestrations?tabs=csharp#orchestrator-code-constraints

Topics

#Durable Functions#orchestrator determinism#workflow patterns#Azure Functions

Community Discussion

No community discussion yet for this question.

Full AZ-204 Practice