Search code examples
c#wcfmsmqwcf-client

WCF and Queuing calls


Have been playing with WCF IIS & self hosted solution (i think i said that right). Basically, copies of the same codebase, hosted websites are talking to each other.

When an event occurs, I need to connect a client to a number of endpoints to send a message. I would like to queue those calls and have them occur async.

I was wondering if I should place in a msmq, either the client ready to call the method or an endpoint and message or something. Then have a windows services pick jobs off the queue to send out messages.

Am I going down some legacy path and missing out on some functionality that WCF has?

Some clues as the best way to do this?

thanks


Solution

  • This sounds like the perfect use case for a publish/subscribe service bus such as NServiceBus. Basically you dispatch a message from your website endpoint (using NServiceBus on top of MSMQ). Another endpoint makes some decisions based upon the message received from the website and then publishes the results of that decision in the form of an event to all interested subscribers.