Skip to content

Latest commit

 

History

History
33 lines (25 loc) · 1.31 KB

README.md

File metadata and controls

33 lines (25 loc) · 1.31 KB

Dapr Mini API

This is my personal playground for experimenting with Dapr and the .NET 6.0 Minimal APIs.

I'm personally enamoured with the idea of what Dapr is bringing to the table, and I like the simplicity of using C# 9's Top-level statements to create applications and micro-services. These two combined create a wonderfully small application which could offer a very compelling platform for work.

Contents

This repo contains two .NET applications:

  • publisher - A console application for publishing a counter.
  • subscriber - A Minimal API app using Dapr to store its state, and receive updates from the publisher.

Getting Started

Skip steps if you know what you're doing. 😈

  1. Install Dapr.
  2. Install Dotnet - .NET 6.0 Preview 7 or later.
  3. Initialize Dapr - dapr init.
  4. Run the subscriber - From the subscriber directory, run the app in dapr: dapr run -a dapr-mini-api-sub --app-port 5000 dotnet watch run
  5. Run the publisher - From the publisher directory, run the app in dapr: dapr run -a dapr-mini-api-pub dotnet watch run
  6. Profit? 💸