quickstarts/pub_sub/csharp/http
MD Ashique 00bf6b50d7 assigning different ports to each apps running under csharp workflow
Signed-off-by: MD Ashique <noorani.ashique5@gmail.com>
2023-03-09 18:29:23 +05:30
..
checkout change order_pub_sub to orderpubsub (#654) 2022-04-26 16:10:19 -07:00
order-processor assigning different ports to each apps running under csharp workflow 2023-03-09 18:29:23 +05:30
README.md assigning different ports to each apps running under csharp workflow 2023-03-09 18:29:23 +05:30
checkout.sln create http and sdk directories for each language 2022-02-14 15:57:15 -08:00
makefile Removed docker image prefix addition step 2022-07-25 12:28:57 -07:00

README.md

Dapr pub/sub (HTTP Client)

In this quickstart, you'll create a publisher microservice and a subscriber microservice to demonstrate how Dapr enables a publish-subcribe pattern. The publisher will generate messages of a specific topic, while subscribers will listen for messages of specific topics. See Why Pub-Sub to understand when this pattern might be a good choice for your software architecture.

Visit this link for more information about Dapr and Pub-Sub.

Note: This example leverages HTTPClient only. If you are looking for the example using the Dapr Client SDK (recommended) click here.

This quickstart includes one publisher:

  • Dotnet client message generator checkout

And one subscriber:

  • Dotnet subscriber order-processor

Run Dotnet message subscriber with Dapr

  1. Navigate to the directory and install dependencies:
cd ./order-processor
dotnet restore
dotnet build
  1. Run the Dotnet subscriber app with Dapr:
dapr run --app-id order-processor-http --resources-path ../../../components/ --app-port 7004 -- dotnet run --project .

Run Dotnet message publisher with Dapr

  1. Navigate to the directory and install dependencies:
cd ./checkout
dotnet restore
dotnet build
  1. Run the Dotnet publisher app with Dapr:
dapr run --app-id checkout-http --resources-path ../../../components/ -- dotnet run --project .
dapr stop --app-id order-processor-http
dapr stop --app-id checkout-http