Currently,  ScriptCS.Rebus uses MSMQ as transport mechanism. In the latest release of ScriptCs.Rebus, I’ve included support for RabbitMQ and console logging.

RabbitMQ is a widely used and rock-solid messaging framework. In my original post, I outlined how to get started using ScriptCs and ScriptCs.Rebus in particular, I’ll therefore urge the reader to read that post prior to this one.

What’s New

Besides major refactorings and code clean-up, the two main features of 0.3.0 is support for RabbitMQ and console logging.

Support for RabbitMQ

I’ve been very trying to be very consistent with the original design, and therefore configuring ScriptCs.Rebus for RabbitMQ is very straightforward:

Copy to Clipboard

This will configure the bus to use the default RabbitMQ port, amqp://localhost:5672, which requires a local server. This configuration is equivalent to using ScriptCs.Rebus with MSMQ, with additional RabbitMQ features. Usually, a remote server is used, and to supply a connectionstring, use the following configuration:

Copy to Clipboard

With this configuration the message of type String will be sent to the remote server. Likewise when you to need receive messages from the remote server, configuration follow the same setup as of the one from MSMQ:

Copy to Clipboard

Console Logging

Working with message busses can often be very complex and a blackbox. Since Rebus has a nice and very useful console logging, it makes so much sense to support this as an option for script authors. Console logging is available for both MSMQ and RabbitMQ busses. By default console logging is disabled. To enable console logging, just add UseLogging() to your configuration:

Copy to Clipboard

Now console logging is enabled and will output some nice logging like this:

Copy to Clipboard

That’s it for 0.3.0, get it, use it, and let me know what you think of it.

Recent Posts

Tags