How should an WCF receiver service monitor an MSMQ queue and service requests in a real-world environment?
I have a service that queues requests in MSMQ. On the other side I have a WCF service that can handle those requests. How can I have the WCF receiver service respond when messages are available on the queu开发者_如何学Pythone?
You are using the netMsmqBinding or the msmqIntegrationBinding?
Then your service method will automatically be called when a message is placed on the queue.
To ensure this, your OperationContract should look similar to this:
[OperationContract(IsOneWay = true, Action = "*")]
void HandleMyMessage (MsmqMessage<String> message);
Hope this helps some
精彩评论