• This repository has been archived on 02/Mar/2022
  • Stars
    star
    216
  • Rank 183,179 (Top 4 %)
  • Language
    TypeScript
  • License
    MIT License
  • Created over 5 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A monitoring/debugging UI tool for Azure Durable Functions

THIS PROJECT HAS MOVED TO https://github.com/microsoft/DurableFunctionsMonitor


logo

Durable Functions Monitor

A monitoring/debugging UI tool for Azure Durable Functions

Azure Durable Functions provide an easy and elegant way of building cloud-native Reliable Stateful Services in the Serverless world. The only thing that's missing so far is a UI for monitoring, managing and debugging your orchestration instances. This project tries to bridge the gap.

Nuget GitHub Repo stars

Visual Studio Marketplace Installs Nuget

Prerequisites

To run this on your devbox you need to have Azure Functions Core Tools globally installed (which is normally already the case, if you're working with Azure Functions - just ensure that you have the latest version of it).

OR

Docker Desktop, if you prefer to run it locally as a container.

How to run

As a VsCode Extension.

  • Install it from the Marketplace or from a VSIX-file.
  • (if you have Azure Functions extension also installed) Goto Azure Functions View Container, observe all your TaskHubs under DURABLE FUNCTIONS tab and click on them to connect.
  • (if not) Type Durable Functions Monitor in your Command Palette and then confirm or provide Storage Connection String and Hub Name.

OR

As a standalone service, either running locally on your devbox or deployed into Azure: Deploy to Azure

OR

Install it as a NuGet package into your own Functions project (.Net Core only).

Features

1. View the list of your Orchestrations and/or Durable Entities, with sorting, infinite scrolling and auto-refresh:

2. Filter by time range and column values:

3. Visualize the filtered list of instances as a Time Histogram or as a Gantt chart:

4. Start new orchestration instances:

5. Monitor the status of a certain instance:

6. Quickly navigate to a certain instance by its ID:

7. Observe Sequence Diagrams and Gantt Charts for orchestrations:

8. Restart, Purge, Rewind, Terminate, Raise Events, Set Custom Status:

9. Purge Orchestration/Entity instances history:

10. Clean deleted Durable Entities:

11. Create custom Orchestration/Entity status tabs with Liquid Templates:

  1. Create a Liquid template file and name it like [My Custom Tab Name].[orchestration-or-entity-name].liquid or just [My Custom Tab Name].liquid (this one will be applied to any kind of entity).
  2. In the same Storage Account (the account where your Durable Functions run in) create a Blob container called durable-functions-monitor.
  3. Put your template file into a tab-templates virtual folder in that container (the full path should look like /durable-functions-monitor/tab-templates/[My Custom Tab Name].[orchestration-or-entity-name].liquid).
  4. Restart Durable Functions Monitor.
  5. Observe the newly appeared My Custom Tab Name tab on the Orchestration/Entity Details page:

Sample Liquid Template:

 <h2>These people were invited:</h2>
 <ul>
 {% for participant in Input.Participants %}
   <li><h3>{{participant}}<h3></li>
 {% endfor %}
 </ul>  

You can have multiple templates for each Orchestration/Entity type, and also multiple 'common' (applied to any Orchestration/Entity) templates. Here is a couple of more sample templates.

NOTE1: this .Net object is passed to your templates as a parameter. Mind the property names and their casing.

NOTE2: code inside your templates is still subject to these Content Security Policies, so no external scripts, sorry.

12. Connect to different Durable Function Hubs and Azure Storage Accounts:

13. Monitor non-default Storage Providers (Netherite, Microsoft SQL, etc.):

For that you can use Durable Functions Monitor in 'injected' mode, aka added as a NuGet package to your project.

  1. Create a .Net Core Function App project, that is configured to use an alternative Storage Provider and make sure it compiles and starts.
  2. Add DurableFunctionsMonitor.DotNetBackend package to it:
 dotnet add package DurableFunctionsMonitor.DotNetBackend
  1. Add mandatory initialization code, that needs to run at your Function's startup:
[assembly: WebJobsStartup(typeof(StartupNs.Startup))]
namespace StartupNs 
{
  public class Startup : IWebJobsStartup
  {
     public void Configure(IWebJobsBuilder builder)
     {
        DfmEndpoint.Setup();
     }
  }
}

Find more details on programmatic configuration options in the package readme.

  1. Run the project:
 func start
  1. Navigate to http://localhost:7071/api. You can customize the endpoint address as needed, as described here.

14. Visualize your Azure Function projects in form of an interactive graph:

This functionality is powered by az-func-as-a-graph tool, but now it is also fully integrated into Durable Functions Monitor: image

When running Durable Functions Monitor as VsCode Extension, the Functions Graph tab should appear automatically, once you have the relevant Functions project opened.

When running in standalone/injected mode you'll need to generate and upload an intermediate Functions Map JSON file.

  1. Generate it with az-func-as-a-graph CLI. Specify dfm-func-map.<my-task-hub-name>.json (will be applied to that particular Task Hub only) or just dfm-func-map.json (will be applied to all Task Hubs) as the output name.
  2. Upload this generated JSON file to function-maps virtual folder inside durable-functions-monitor BLOB container in the underlying Storage Account (the full path should look like /durable-functions-monitor/function-maps/dfm-func-map.<my-task-hub-name>.json).
  3. Restart Durable Functions Monitor.
  4. Observe the newly appeared Functions Graph tab.

More Repositories

1

az-func-as-a-graph

Visualizes your Azure Functions project in form of a graph
TypeScript
52
star
2

linq2dynamodb

A type-safe data context for AWS DynamoDB with LINQ and in-memory caching support. Allows to combine DynamoDB's durability with cache speed and read consistency
C#
42
star
3

ThrottlingTroll

Rate limiting/throttling middleware for ASP.NET and Azure Functions
C#
23
star
4

cognitive-search-static-web-apps-sample-ui

A simple sample UI for your Azure AI Search index. Built with React, TypeScript and Azure Static Web Apps
TypeScript
21
star
5

sftp-watcher

Monitors the contents of given SFTP folders and emits Azure Storage Queue/Service Bus/Event Grid events for files being created/removed/modified. Implemented with Azure Functions Durable Entities and SSH.NET.
C#
15
star
6

durable-mvc-starter

Basic project setup and scaffolding for creating serverless web applications based on Azure Durable Entities, Azure SignalR Service, React+MobX and TypeScript
TypeScript
12
star
7

kee-shepherd

A credentials hygiene tool. Keeps an eye on secrets, that are spread across your devboxes. Also includes UI for Azure Key Vault, GitHub Secrets and VsCode SecretStorage. Also hides secrets in your config files (super-useful when doing demos)
TypeScript
11
star
8

AzFunc4DevOps

Azure DevOps Triggers and Bindings for Azure Functions
C#
6
star
9

react-ts-basic

A GitHub template for quickly bootstrapping an Azure Static Web App project with React, TypeScript and Azure Functions.
HTML
5
star
10

azure-function-pump-data-to-delta-lake

Azure Function to pump events from an Azure Service Bus/Event Hub/Storage Queue into a Delta Lake table in Azure Databricks.
Python
4
star
11

LetsGoOutDemo

A demo project to demonstrate various approaches to building stateful services in Azure
C#
3
star
12

azure-resource-explorer-vscode

Azure Resource Explorer as a VsCode extension
TypeScript
3
star
13

azure-products-graph

All known Azure products and services visualized in form of a graph and hosted with Azure Static Web Apps..
TypeScript
2
star
14

nservicebus-azure-functions-demo

Demonstrates how to build and host NServiceBus-based services with Azure Functions and Azure Service Bus
C#
1
star
15

repka-durable-func

Reverses a linked list with Azure Durable Functions. For demo purposes only. Sample linked list comes from https://en.wikipedia.org/wiki/The_Gigantic_Turnip folktale.
Liquid
1
star
16

durable-mvc-samples

A set of samples for https://github.com/scale-tone/durable-mvc-starter
TypeScript
1
star
17

MultiThreadingWalkthrough

C#
1
star
18

WhatIfDemo

A set of demo projects for Azure Serverless
JavaScript
1
star