leoguilen / dotnet-pulsar-pubsub

Demonstrates how to use the Apache Pulsar Pub/Sub messaging service using the C# client library (DotPulsar).

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Pub/Sub Apache Pulsar 📨

Demonstrates how to use the Apache Pulsar Pub/Sub messaging service using the C# client library.

How to run

  1. Clone this repository
  2. Execute the following script to up the Apache P Pulsar service using Docker Compose:
chmod +x ./scripts/deploy-local-environment.sh 
./scripts/deploy-local-environment.sh
  1. Run the Producer project:
dotnet run --project src/Producer
  1. Run the Consumer project:
dotnet run --project src/Consumer
  1. Make a request to the Producer API project to send a message to the Pulsar broker:
curl -X POST "http://<host>/api/messages" -H "Content-Type: application/json" -d '{"content": "Hello, Pulsar!"}'

Resources

About

Demonstrates how to use the Apache Pulsar Pub/Sub messaging service using the C# client library (DotPulsar).


Languages

Language:C# 98.1%Language:Shell 1.9%