简体   繁体   English

MSMQ,WCF和Flaky服务器

[英]MSMQ, WCF, and Flaky Servers

I have two applications, let us call them A and B. Currently A uses WCF to send messages to B. A doesn't need a response and B never sends messages back to A. 我有两个应用程序,让我们称它们为A和B.目前A使用WCF向B发送消息.A不需要响应,B从不将消息发送回A.

Unfortunately, there is a flaky network connection between the servers A and B are running on. 不幸的是,运行的服务器A和B之间存在片状网络连接。 This results in A getting timeout errors from time to time. 这会导致A不时出现超时错误。

I would like to use WCF+MSMQ as a buffer between the two applications. 我想使用WCF + MSMQ作为两个应用程序之间的缓冲区。 That way if B goes down temporarily, or is otherwise inaccessible, the messages are not lost. 这样,如果B暂时中断或者无法访问,则消息不会丢失。

From an architectural standpoint, how should I configure this? 从架构的角度来看,我该如何配置?

I think you might have inflated your question a bit with the inclusion of the word "architectural". 我想你可能会因为包含“架构”这个词而夸大了你的问题。

If you truly need an architectural overview of this issue from that high of a level, including SLA concerns, your SL will be as good as your MSMQ deployment, so if you are concerned about SL, just look at the documentation on the internet about MSMQ and SLA. 如果您真的需要从这个高级别(包括SLA问题)获得此问题的架构概述 ,那么您的SL将与MSMQ部署一样好,因此如果您关注SL,请查看Internet上有关MSMQ的文档和SLA。

If you are looking more for the actual implementation from a code standpoint, this article is excellent: http://code.msdn.microsoft.com/msmqpluswcf 如果您从代码的角度来看更多的实际实现 ,本文非常好: http//code.msdn.microsoft.com/msmqpluswcf

It goes over a lot of the things you'll need to know, including how to setup MSMQ and how to implement chunking to get around MSMQ's 4MB limit (if this is necessary... I hope it's not). 它包含了许多您需要了解的内容,包括如何设置MSMQ以及如何实现分块以绕过MSMQ的4MB限制(如果这是必要的......我希望不是这样)。

Here's a good article about creating a durable and transactional queue that will cross machines using an MSMQ cluster: http://www.devx.com/enterprise/Article/39015/1954 这是一篇关于创建一个使用MSMQ集群跨机器的持久和事务性队列的好文章: http//www.devx.com/enterprise/Article/39015/1954

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM