RudyMQ: A rudimentary message queue for Windows

To skip to the source code, click here.

For some odd reason out of the blue, I got this hankering to build a message queue (albeit rudimentary – hence the name) from scratch. I’ve been working with MSMQ for a while now, mostly as a transport for WCF. As cool as it is, it can really get on your nerves at times. It is an enterprise grade product, after all, which means there are a lot of dials you can turn. If something is not right, you’ll get an error. If your experience has been the same as mine, you will recognize the dreaded insufficient resources error that MSMQ gives you for almost any of a thousand things that can go wrong.

That got me thinking that if in most cases, I don’t really need all the enterprise grade features of MSMQ, a simpler managed-code version may suffice. .NET gives you many varieties of queue or queue-type data structures that one could leverage and combine with something like WCF to build a message queue. The only serious issues you would have to deal with, I guess, would be concurrence and performance. The use of read-write locks greatly helped with both, although I foolishly did not keep a record of the performance test results around.

Anyway, you can find more details over here. Feedback appreciated as always. You can also find the source code here.

As I think back, I think it took me longer to get the WCF binding working than the actual message queue itself. If you think just using WCF is a chore, try building your own channels. The lack of available documentation online and how to get something like this working end-to-end was shocking. So, that – I believe – is another blog post in the works.


3 thoughts on “RudyMQ: A rudimentary message queue for Windows

  1. Pingback: Reader/Writer Locking in .NET | Aashish Koirala

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s