NServiceBus:使用 NServiceBus Distributor 的优缺点 [英] NServiceBus: Pros and Cons of using NServiceBus Distributor

查看:45
本文介绍了NServiceBus:使用 NServiceBus Distributor 的优缺点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在考虑使用网络负载均衡器在我的订阅者实例之间对消息进行负载均衡,而不是使用 NServiceBus 分发器(据我所知,它基本上只是一个软件负载均衡器).每个订阅者实例都会有一个同名的消息队列,用于传递消息,并且会有一个虚拟 IP 在订阅者之间进行循环.发布者只会知道虚拟 IP 和队列名称.

I am considering using a Network Load Balancer to load balance messages between my subscriber instances, instead of using the NServiceBus distributor (which is basically just a software load-balancer from what I can tell). Each subscriber instance will have a queue of the same name for messages to be delivered to, and there will be a virtual IP that round-robins between the subscribers. The publisher will only know about the virtual IP and queue name.

以下是我对这样做的利弊的理解:

Here is what I understand as the pros and cons of doing this:

  1. 优点
    • 无需安装 NServiceBus Distributor
    • 横向扩展时需要管理/更新的另一件事(我们已经使用 F5 来对这些机器进行负载平衡,我们的数据中心采购人员对此了如指掌)
    • 少一个故障点(是的,NLB 可能会失败,但让我们面对现实,F5 将比在 Windows 上运行的 NServiceBus Distributor 稳定得多)
    • 无需集群服务器即可拥有我们的集群 MSMQ.2 个服务器比仅向 F5 添加另一个 VIP 贵得多.
  • NServiceBus 分发器使您可以更轻松地查看消息的积压,因为分发器上有一个您可以监控的队列.这让您很容易知道何时应该添加更多工作节点.
  • NServiceBus Distributor 在控制工作线程的数量等方面更智能.比 NLB 给您更多的控制?(不确定这个)

我是否准确地捕捉到了这一点?我知道建议使用 NServiceBus Distributor,在我反对该建议之前,我想了解更多原因.

Have I captured this accurately? I know it is recommended to use the NServiceBus Distributor, and I would like to know more of why before I go against that recommendation.

推荐答案

您已经了解了一些要点,但主要区别之一是,由于分配器会自行加载,如果机器要运行下来,其余的负载将在其余机器之间分配,对消息的 SLA 影响要低得多.

Youve' got some of the main points down, but one of the main differences is that since the distributor holds on to load itself, if a machine were to go down, the rest of the load would be distributed between the remaining machines with a much lower SLA impact on the messages.

这篇关于NServiceBus:使用 NServiceBus Distributor 的优缺点的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆