All Projects → pardahlman → Rawrabbit

pardahlman / Rawrabbit

Licence: mit
A modern .NET framework for communication over RabbitMq

Projects that are alternatives of or similar to Rawrabbit

Qmq
QMQ是去哪儿网内部广泛使用的消息中间件,自2012年诞生以来在去哪儿网所有业务场景中广泛的应用,包括跟交易息息相关的订单场景; 也包括报价搜索等高吞吐量场景。
Stars: ✭ 2,420 (+254.84%)
Mutual labels:  rabbitmq, message-bus
Message Bus
Go simple async message bus
Stars: ✭ 166 (-75.66%)
Mutual labels:  async, message-bus
Enqueue Bundle
[READ-ONLY] Message queue bundle for Symfony. RabbitMQ, Amazon SQS, Redis, Service bus, Async events, RPC over MQ and a lot more
Stars: ✭ 233 (-65.84%)
Mutual labels:  rabbitmq, message-bus
Dotnetlabs
.NET Labs -- Show Me the Tips and Tricks and Code
Stars: ✭ 135 (-80.21%)
Mutual labels:  rabbitmq, dotnetcore
Benthos
Fancy stream processing made operationally mundane
Stars: ✭ 3,705 (+443.26%)
Mutual labels:  rabbitmq, message-bus
Enqueue Dev
Message Queue, Job Queue, Broadcasting, WebSockets packages for PHP, Symfony, Laravel, Magento. DEVELOPMENT REPOSITORY - provided by Forma-Pro
Stars: ✭ 1,977 (+189.88%)
Mutual labels:  rabbitmq, message-bus
Aiormq
Pure python AMQP 0.9.1 asynchronous client library
Stars: ✭ 112 (-83.58%)
Mutual labels:  async, rabbitmq
Tossit
Library for distributed job/worker logic.
Stars: ✭ 56 (-91.79%)
Mutual labels:  rabbitmq, dotnetcore
OpenSleigh
OpenSleigh is a Saga management library for .NET Core.
Stars: ✭ 198 (-70.97%)
Mutual labels:  rabbitmq, message-bus
docker-workshop-with-react-aspnetcore-redis-rabbitmq-mssql
An Asp.Net Core Docker workshop project that includes react ui, redis, mssql, rabbitmq and azure pipelines
Stars: ✭ 53 (-92.23%)
Mutual labels:  rabbitmq, dotnetcore
Eventflow.example
DDD+CQRS+Event-sourcing examples using EventFlow following CQRS-ES architecture. It is configured with RabbitMQ, MongoDB(Snapshot store), PostgreSQL(Read store), EventStore(GES). It's targeted to .Net Core 2.2 and include docker compose file.
Stars: ✭ 131 (-80.79%)
Mutual labels:  rabbitmq, dotnetcore
Servicebus
Simple service bus for sending events between processes using amqp.
Stars: ✭ 415 (-39.15%)
Mutual labels:  rabbitmq, message-bus
Dotnet Istanbul Microservices Demo
This is the demo application that i created for my talk 'Microservice Architecture & Implementation with Asp.Net Core' at Dotnet İstanbul Meetup Group.
Stars: ✭ 109 (-84.02%)
Mutual labels:  rabbitmq, dotnetcore
Messagebus
A MessageBus (CommandBus, EventBus and QueryBus) implementation in PHP7
Stars: ✭ 178 (-73.9%)
Mutual labels:  rabbitmq, message-bus
Quiz
Example real time quiz application with .NET Core, React, DDD, Event Sourcing, Docker and built-in infrastructure for CI/CD with k8s, jenkins and helm
Stars: ✭ 100 (-85.34%)
Mutual labels:  rabbitmq, dotnetcore
Yii2 Queue
Yii2 Queue Extension. Supports DB, Redis, RabbitMQ, Beanstalk and Gearman
Stars: ✭ 977 (+43.26%)
Mutual labels:  async, rabbitmq
Carrot
Carrot is a .NET lightweight library that provides a couple of facilities over RabbitMQ.
Stars: ✭ 14 (-97.95%)
Mutual labels:  rabbitmq, dotnetcore
Dotnext
Next generation API for .NET
Stars: ✭ 379 (-44.43%)
Mutual labels:  async, dotnetcore
Plumber
A swiss army knife CLI tool for interacting with Kafka, RabbitMQ and other messaging systems.
Stars: ✭ 514 (-24.63%)
Mutual labels:  rabbitmq, message-bus
P Map
Map over promises concurrently
Stars: ✭ 639 (-6.3%)
Mutual labels:  async

Looking for documentation of 1.x? Click here

RawRabbit

Build Status Documentation Status NuGet GitHub release Slack Status

Quick introduction

RawRabbit is a modern .NET framework for communication over RabbitMQ. The modular design and middleware oriented architecture makes the client highly customizable while providing sensible default for topology, routing and more. Documentation for version 2.x of the is currently found under /docs.

Configure, enrich and extend

RawRabbit is configured with RawRabbitOptions, an options object that makes it possible to register client configuration, plugins as well as override internal services

var client = RawRabbitFactory.CreateSingleton(new RawRabbitOptions
{
  ClientConfiguration = new ConfigurationBuilder()
    .SetBasePath(Directory.GetCurrentDirectory())
    .AddJsonFile("rawrabbit.json")
    .Build()
    .Get<RawRabbitConfiguration>(),
  Plugins = p => p
    .UseProtobuf()
    .UsePolly(c => c
        .UsePolicy(queueBindPolicy, PolicyKeys.QueueBind)
        .UsePolicy(queueDeclarePolicy, PolicyKeys.QueueDeclare)
        .UsePolicy(exchangeDeclarePolicy, PolicyKeys.ExchangeDeclare)
    ),
  DependencyInjection = ioc => ioc
    .AddSingleton<IChannelFactory, CustomChannelFactory>()
});

Publish/Subscribe

Set up strongly typed publish/subscribe in just a few lines of code.

var client = RawRabbitFactory.CreateSingleton();
await client.SubscribeAsync<BasicMessage>(async msg =>
{
  Console.WriteLine($"Received: {msg.Prop}.");
});

await client.PublishAsync(new BasicMessage { Prop = "Hello, world!"});

Request/Response

RawRabbits request/response (RPC) implementation uses the direct reply-to feature for better performance and lower resource allocation.

var client = RawRabbitFactory.CreateSingleton();
client.RespondAsync<BasicRequest, BasicResponse>(async request =>
{
  return new BasicResponse();
});

var response = await client.RequestAsync<BasicRequest, BasicResponse>();

Ack, Nack, Reject and Retry

Unlike many other clients, basic.ack, basic.nack and basic.reject are first class citizen in the message handler

var client = RawRabbitFactory.CreateSingleton();
await client.SubscribeAsync<BasicMessage>(async msg =>
{
  if(UnableToProcessMessage(msg))
  {
    return new Nack(requeue: true);
  }
  ProcessMessage(msg)
  return new Ack();
});

In addition to the basic acknowledgements, RawRabbit also support delayed retries

var client = RawRabbitFactory.CreateSingleton();
await client.SubscribeAsync<BasicMessage>(async msg =>
{
  try
  {
    ProcessMessage(msg)
    return new Ack();
  }
  catch (Exception e)
  {
    return Retry.In(TimeSpan.FromSeconds(30));
  }
});

Granular control for each call

Add or change properties in the IPipeContext to tailor calls for specific type of messages. This makes it possible to modifly the topology features for calls, publish confirm timeout, consumer concurrency and much more

await subscriber.SubscribeAsync<BasicMessage>(received =>
{
  receivedTcs.TrySetResult(received);
  return Task.FromResult(true);
}, ctx => ctx
  .UseSubscribeConfiguration(cfg => cfg
    .Consume(c => c
      .WithRoutingKey("custom_key")
      .WithConsumerTag("custom_tag")
      .WithPrefetchCount(2)
      .WithNoLocal(false))
    .FromDeclaredQueue(q => q
      .WithName("custom_queue")
      .WithAutoDelete()
      .WithArgument(QueueArgument.DeadLetterExchange, "dlx"))
    .OnDeclaredExchange(e=> e
      .WithName("custom_exchange")
      .WithType(ExchangeType.Topic))
));
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].