Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/EasyNetQ/EasyNetQ
An easy to use .NET API for RabbitMQ
https://github.com/EasyNetQ/EasyNetQ
dotnet dotnet-core messaging rabbitmq
Last synced: 2 days ago
JSON representation
An easy to use .NET API for RabbitMQ
- Host: GitHub
- URL: https://github.com/EasyNetQ/EasyNetQ
- Owner: EasyNetQ
- License: mit
- Created: 2011-04-21T15:47:20.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2024-09-20T14:18:27.000Z (about 2 months ago)
- Last Synced: 2024-11-01T11:18:27.661Z (7 days ago)
- Topics: dotnet, dotnet-core, messaging, rabbitmq
- Language: C#
- Homepage: http://easynetq.com
- Size: 68.6 MB
- Stars: 2,900
- Watchers: 157
- Forks: 749
- Open Issues: 79
-
Metadata Files:
- Readme: README.md
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
- awesome-reference-tools - EasyNetQ
- Awesome-Microservices-DotNet - EasyNetQ - An easy to use .NET API for RabbitMQ (Tools and Libraries / Messaging)
- fucking-awesome-dotnet-core - EasyNetQ - An easy to use .NET API for RabbitMQ. (Frameworks, Libraries and Tools / Queue and Messaging)
- awesome-dotnet-core - EasyNetQ - An easy to use .NET API for RabbitMQ. (Frameworks, Libraries and Tools / Queue and Messaging)
README
[![Build status](https://github.com/EasyNetQ/EasyNetQ/workflows/CI/badge.svg)](https://github.com/EasyNetQ/EasyNetQ/actions?query=workflow%3ACI)
[![NuGet Status](https://img.shields.io/nuget/v/EasyNetQ)](https://www.nuget.org/packages/EasyNetQ)
[![Nuget Status](https://img.shields.io/nuget/vpre/EasyNetQ)](https://www.nuget.org/packages/EasyNetQ/absoluteLatest)
[![Nuget Status](https://img.shields.io/nuget/dt/EasyNetQ)](https://www.nuget.org/packages/EasyNetQ)![Activity](https://img.shields.io/github/commit-activity/w/EasyNetQ/easynetq)
![Activity](https://img.shields.io/github/commit-activity/m/EasyNetQ/easynetq)
![Activity](https://img.shields.io/github/commit-activity/y/EasyNetQ/easynetq)
--![EasyNetQ Logo](https://github.com/EasyNetQ/EasyNetQ/wiki/images/logo_design_150.png)
A Nice .NET API for RabbitMQ
Initial development was sponsored by travel industry experts [15below](http://15below.com/)
* **[Homepage](http://easynetq.com)**
* **[Documentation](https://github.com/EasyNetQ/EasyNetQ/wiki/Introduction)**
* **[NuGet](http://www.nuget.org/packages/EasyNetQ)**
* **[Discussions](https://github.com/EasyNetQ/EasyNetQ/discussions)**
* **[~Old Discussion Group~](https://groups.google.com/group/easynetq)**Goals:
### Important Update
With the release of EasyNetQ v8, the method for connecting to a RabbitMQ broker has changed. The rest of the API remains unchanged.
To make working with RabbitMQ on .NET as easy as possible.
To connect to a RabbitMQ broker in v7...
```c#
var bus = RabbitHutch.CreateBus("host=localhost");
```To connect to a RabbitMQ broker in v8...
```c#
var serviceCollection = new ServiceCollection();
serviceCollection.AddEasyNetQ("host=localhost").UseSystemTextJson();using var provider = serviceCollection.BuildServiceProvider();
var bus = provider.GetRequiredService();
```To publish a message...
```c#
await bus.PubSub.PublishAsync(message);
```To publish a message with a 5s delay...
```c#
await bus.Scheduler.FuturePublishAsync(message, TimeSpan.FromSeconds(5));
```To subscribe to a message...
```c#
await bus.PubSub.SubscribeAsync(
"my_subscription_id", msg => Console.WriteLine(msg.Text)
);```
Remote procedure call...
```c#
var request = new TestRequestMessage {Text = "Hello from the client! "};
await bus.Rpc.RequestAsync(request);
```RPC server...
```c#
await bus.Rpc.RespondAsync(request =>
new TestResponseMessage{ Text = request.Text + " all done!" }
);
```## Getting started
Just open EasyNetQ.sln in your preferred IDE or code editor and build. All the required dependencies for the solution file to build the software are included.
## Contributors
Thanks to all the people who already contributed!