WCF 和队列调用
一直在玩WCF IIS &自托管解决方案(我想我说得对)。基本上,相同代码库的副本、托管网站正在相互通信。
当事件发生时,我需要将客户端连接到多个端点以发送消息。我想对这些调用进行排队并使它们异步发生。
我想知道是否应该放入 msmq,客户端准备好调用该方法或端点和消息或其他内容。然后让 Windows 服务从队列中挑选作业来发送消息。
我是否会走上一些旧的道路并错过 WCF 拥有的某些功能?
一些线索是做到这一点的最佳方法?
谢谢
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
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这听起来像是 NServiceBus 等发布/订阅服务总线的完美用例。基本上,您从网站端点发送消息(使用 MSMQ 之上的 NServiceBus)。另一个端点根据从网站收到的消息做出一些决定,然后发布该决定的结果以事件的形式发送给所有感兴趣的订阅者。
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.