Skip to content

diagrid-labs/dapr-resiliency-and-durable-execution

Repository files navigation

Dapr Resiliency and Durable Execution

This repo contains Dapr applications to demonstrate Dapr resiliency policies and durable execution with Dapr workflow.

Running the demos with Demo Time in this repo is recommended since this gives more context about:

  • failure and distributed computing challenges
  • what durable execution is
  • how the Dapr Workflow implements durable execution
  • the way Dapr provides resiliency

Table of Contents

1 - Prerequisites

You can choose to run the demos locally, which requires that you install the required dependencies yourself. Or you use the provided devcontainer that contains all required dependencies.

1a - Run locally without the devcontainer

Ensure you have these installed on your machine:

1b - Run with the devcontainer

Ensure you have these installed on your machine:

The devcontainer configuration is using a .NET 9 image and includes the Dapr CLI and the required VS Code extensions.

2 - Clone the repo

Clone the dapr-resiliency-and-durable-execution repo to your local machine.

Open the cloned repo in VSCode and accept the suggested VSCode extensions or choose to open the repo in the devcontainer.

3 - Run the Durable Execution & Workflow demo with Demo Time

The WorkflowDemo consists of two applications; a WorkflowApp, a ShippingApp, and a state store.

Workflow Demo

The workflow simulates an order validation process that involves checking and updating the inventory, retrieving shipping costs, and registering the shipment with the cheapest shipment provider:

Order Validation Workflow

Using the Demo Time panel in the VSCode explorer, start the 3 - Durable Execution & Workflow demo:

Demo Time

4 - Run the Resiliency demo with Demo Time

The ResiliencyDemo consists of two applications, ValidationService and ProfileService, and a state store.

graph LR
    A{{ValidationService}}
    B{{ProfileService}}
    State[(KV Store)]
    A --HTTP--> B
    B --> State
Loading

Using the Demo Time panel in the VSCode explorer, start the 4 - Dapr Resiliency demo:

Demo Time

5 - Dapr Reliability Advisor in Conductor Free

Diagrid Conductor Free is a free tool developers can use to visualize, troubleshoot, and optimize Dapr workloads on Kubernetes. It includes an Advisor that provides recommendations on how to improve the reliability of your Dapr applications.

Conductor Advisor

Reliability details

6 - Dapr Workflow Composer

Try the Dapr Workflow Composer, a free tool where you can upload a workflow image, or draw one in the browser, and scaffold a complete workflow application.

Dapr Workflow Composer

7 - Resources

About

This repo contains Dapr applications to demonstrate resiliency policies and durable execution with Dapr workflow.

Topics

Resources

License

Stars

Watchers

Forks