[rabbitmq-discuss] Integrating NServiceBus and RabbitMQ

Michael Bridgen mikeb at rabbitmq.com
Tue Jul 20 12:21:59 BST 2010


Hi Udi,

> I've been hearing from many of my clients of the desire to use 
> NServiceBus (an open source .NET service bus) on Linux by using Mono.
> 
> The thing missing is that MSMQ (the default transport used by 
> NServiceBus) isn't available on Linux (duh :-) )
> 
>  
> 
> In terms of high availability and transactional support, I think that 
> RabbitMQ is the best option for enabling the above.
> 
> The thing is if there are certain APIs that should (or should not) be 
> used for working with RabbitMQ in "federated mode" - no central broker. 
> Also, is there anything special that needs to be done to flow 
> transactions from the application level into RabbitMQ and enlisting it 
> into distributed transactions?

On the surface of things, I too would expect RabbitMQ to be suitable for 
backing a message bus; and, RabbitMQ is already used in Mono for messaging:
http://www.mono-project.com/SystemMessaging

That may be enough for what you want to do -- I don't know the .NET APIs 
well enough to judge.

 From your description, though, it looks like NServiceBus's design has 
assumptions about the transport that would make your intended use difficult.

RabbitMQ is designed to be a central broker, in that its model is fitted 
to AMQP, which is a client-broker protocol.  Addresses are scoped to the 
broker.

The MSMQ model, as I understand it, is that the queues are local 
transmission buffers, and addressing is global.

It would take some work to implement the MSMQ model with the AMQP model. 
  In particular I would guess it can't be accomplished without adapting 
the broker (e.g., with a plugin) or at least out-of-band communication 
between clients, which would rather undermine the effort.

We are looking into models of federation, so I'll keep this use case in 
mind.

With regard to distributed transactions, RabbitMQ doesn't support them. 
  If I recall, they were mentioned but not specified in AMQP 0-8, and 
the mention removed in AMQP 0-9-1.  RabbitMQ does support local 
transactions, scoped to channels.  But again, I think it would require 
modification (and probably substantial development) to support 
distributed transactions.


Regards,
Michael


More information about the rabbitmq-discuss mailing list