<p>I'm working on a messaging/notification system for our products.  Basic requirements are:</p>

<ul>
<li>Fire and forget</li>
<li>Persistent set of messages, possibly updating, to stay there until the sender says to remove them</li>
</ul>

<p>The libraries will be written in C#.  Spring.NET just released a milestone build with lots of nice messaging abstraction, which is great - I plan on using it extensively.  My basic question comes down to the question of message brokers.  My architecture will look something like app -> message broker queue -> server app that listens, dispatches all messages to where they need to go, and handles the life cycle of those long-lived messages -> message broker queue or topic -> listening apps.</p>

<p>Finally, the question:  Which message broker should I use?  I am biased towards <a href="http://activemq.apache.org" rel="noreferrer">ActiveMQ</a> - We used it on our last project and loved it.  I can't really think of a single strike against it, except that it's Java, and will require java to be installed on a server somewhere, and that might be a hard sell to some of the people that will be using this service.  The other option I've been looking at is MSMQ.  I am biased against it for some unknown reason, and it also doesn't seem to have great multicast support.</p>

<p>Has anyone used MSMQ for something like this?  Any pros or cons, stuff that might sway the vote one way or the other?</p>

<p>One last thing, we are using .NET 2.0.</p>

[{'answer_id': 33181, 'author': 'Darryl Braaten', 'author_id': 1834, 'author_profile': 'https://Stackoverflow.com/users/1834', 'pm_score': 4, 'selected': False, 'text': '<p>Pros for MSMQ.</p>\n\n<ul>\n<li>It is built into Windows</li>\n<li>It supports transactions, it also supports queues with no transactions</li>\n<li>It is really easy to setup </li>\n<li>AD Integration</li>\n<li>It is fast, but you would need to compare ActiveMQ and MSMQ for your traffic to know which is faster.</li>\n<li>.NET supports it nativity </li>\n<li>Supports fire and forget</li>\n<li>You can peek at the queue, if you have readers that just look. not sure if you can edit a message in the queue.</li>\n</ul>\n\n<p>Cons:</p>\n\n<ul>\n<li>4MB message size limit</li>\n<li>2GB Queue size limit</li>\n<li>Queue items are held on disk</li>\n<li>Not a mainstream MS product,  docs are a bit iffy, or were it has been a few years since I used it.</li>\n</ul>\n\n<p>Here is a good blog for <a href="http://blogs.msdn.com/johnbreakwell/default.aspx" rel="noreferrer">MSMQ</a></p>\n'}, {'answer_id': 72557, 'author': 'James Strachan', 'author_id': 2068211, 'author_profile': 'https://Stackoverflow.com/users/2068211', 'pm_score': 6, 'selected': True, 'text': '<p>I\'m kinda biased as I work on <a href="http://activemq.apache.org" rel="noreferrer">ActiveMQ</a> but pretty much all of benefits listed for MSMQ above also apply to ActiveMQ really. </p>\n\n<p>Some more benefits of ActiveMQ include</p>\n\n<ul>\n<li>great support for <a href="http://activemq.apache.org/cross-language-clients.html" rel="noreferrer">cross language client access and multi protocol support</a> </li>\n<li>excellent support for <a href="http://activemq.apache.org/enterprise-integration-patterns.html" rel="noreferrer">enterprise integration patterns</a></li>\n<li>a ton of <a href="http://activemq.apache.org/features.html" rel="noreferrer">advanced features</a> like <a href="http://activemq.apache.org/exclusive-consumer.html" rel="noreferrer">exclusive queues</a> and <a href="http://activemq.apache.org/message-groups.html" rel="noreferrer">message groups</a></li>\n</ul>\n\n<p>The main downside you mention is that the ActiveMQ broker is written in Java; but you can run it on IKVM as a .net assembly if you really want - or run it as a windows service, or compile it to a DLL/EXE via GCJ. MSMQ may or may not be written in .NET - but it doesn\'t really matter much how its implemented right?</p>\n\n<p>Irrespective of whether you choose MSMQ or ActiveMQ I\'d recommend at least considering using the <a href="http://activemq.apache.org/nms/" rel="noreferrer">NMS API</a> which as you say is integrated great into Spring.NET. There is an MSMQ implementation of this API as well as implementations for TibCo, ActiveMQ and STOMP which will support any other JMS provider via <a href="http://stomp.codehaus.org/StompConnect" rel="noreferrer">StompConnect</a>.</p>\n\n<p>So by choosing NMS as your API you will avoid lockin to any proprietary technology - and you can then easily switch messaging providers at any point in time; rather than locking your code all into a proprietary API</p>\n'}, {'answer_id': 169482, 'author': 'Community', 'author_id': -1, 'author_profile': 'https://Stackoverflow.com/users/-1', 'pm_score': 2, 'selected': False, 'text': '<p>I suggest you have a look at TIBCO Enterprise Messaging Service - EMS, which is a high performance messaging product that supports multicasting, routing, supports JMS specification and provides enterprise wide features including your requirements suchas fire-forget and message persistence using file/database using shared state.</p>\n\n<p>As  a reference, FEDEX runs on TIBCO EMS\nas its messaging infrastructure.</p>\n\n<p><a href="http://www.tibco.com/software/messaging/enterprise_messaging_service/default.jsp" rel="nofollow noreferrer">http://www.tibco.com/software/messaging/enterprise_messaging_service/default.jsp</a></p>\n\n<p>There are lot other references if i provide, you\'d really be surprised.</p>\n'}, {'answer_id': 227644, 'author': 'Autobyte', 'author_id': 6788, 'author_profile': 'https://Stackoverflow.com/users/6788', 'pm_score': 2, 'selected': False, 'text': "<p>There are so many options in that arena...  </p>\n\n<p>Free: MantaRay a peer to peer fully JMS compliant system.  The interesting part of Mantaray is that you only need to define where the message goes and MantaRay routes it anyways that will get your message to it's detination - so it is more resistant to failures of individual nodes in your messaging fabric.  </p>\n\n<p>Paid: At my day job I administer an IBM WebSphere MQ messaging system with several hundred nodes and have found it to be very good.  We also recently purchased Tibco EMS and it seems that it will be pretty nice to use as well.</p>\n\n<p>Paul/</p>\n"}, {'answer_id': 227676, 'author': 'Community', 'author_id': -1, 'author_profile': 'https://Stackoverflow.com/users/-1', 'pm_score': 3, 'selected': False, 'text': '<p>Take a look at <a href="http://www.zeromq.org/" rel="noreferrer">zeromq</a>. It\'s one of the fastest message queues around.</p>\n'}]
['https://Stackoverflow.com/questions/32851', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/96/']