1

When going through Azure Durable function they mention that we can write stateful functions. What is meant by stateful and what state is maintained? Are we talking about running state of a function?

2
  • 1
    "You can use Durable Functions for stateful orchestration of function execution. A durable function is a solution that's made up of different Azure functions. Functions can play different roles in a durable function orchestration." Durable Functions types and features (Azure Functions) Commented Apr 15, 2019 at 13:41
  • Hello @kumar now I am having the same question. I am new to Azure. Could you please tell what is "stateful" with regards of Azure Durable Functions. What purpose does it serve that normal Azure functions could not do. Commented Jan 20, 2023 at 10:03

1 Answer 1

2

A stateful function is a function which has a state, that is, some data is asscociated to the function. In our specific case, we are talking about:

  • managing state of the workflow (at what step we are)
  • create progress checkpoints (when a checkpoint is reached, the state is changed)
  • persisting execution history
  • scheduling activity

From the docs:

Durable Functions is an extension to the Azure Functions runtime that enables the definition of stateful workflows in code. By breaking down workflows into activities, the Durable Functions extension can manage state, create progress checkpoints, and handle the distribution of function calls across servers. In the background, it makes use of an Azure Storage account to persist execution history, schedule activity functions and retrieve responses. Your serverless code should never interact with persisted information in that storage account, and is typically not something with which developers need to interact.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.