tags:

views:

218

answers:

4

In my current project, I have a slightly distributed architecture, i.e., several executables collaborate with each other to get things done. To make things easier, i hope i could have a reliable 'backbone' message bus: when an executable hooks up to the msg bus, it can receive callback when new msg arrives. Similarly, it can publish new message to the bus.

I know some companies provide off-the-shelf solutions like this, however, is there any free ones in the OSS?

+3  A: 

Have you given a thought to using AMQP based like RabbitMQ?

There are some libraries for C binding you could "dress-up" for C++.

RabbitMQ is a complete and highly reliable enterprise messaging system based on the emerging AMQP standard. It is licensed under the open source Mozilla Public License and has a platform-neutral distribution, plus platform-specific packages and bundles for easy installation.


Of course, if you require something "less-distributed" you could go straight to using DBus.

jldupont
+4  A: 

If you don't need Windows support, and your processes aren't spread over different computers, I'd definately give D-Bus a look.

It's written in C and features (according to the web page) bindings for "Qt, GLib, Java, C#, Python, etc.)".

The list of projects using D-Bus is quite impressive, too.

Frerich Raabe
I don't recall D-Bus as being high-performance... or did something change drastically in the last year?
Georg Fritzsche
it also seems that WinDbus, the windows port is lagging behind which is why I never tried to integrated D-Bus in my developments
Gregory Pakosz
+1  A: 

Besides the given answers, Boost.Interprocess should be a portable and performant alternative.
If you're really looking for high performance though, scrap the idea of using the IPC library for in-process-communication too - there will be performance penalties.

Georg Fritzsche
A: 

Similar to the AMQP idea above, you might want to look at ZeroMQ (http://www.zeromq.org/). I haven't used it personally, but I know people who like it a lot.

Eric Anderson