Azure 服务总线中继混合连接负载平衡

Azure Service Bus Relay Hybrid Connections load balancing

中继混合连接是授予对隐藏在防火墙后面的 RESTful Web 服务的访问权限的选项之一。我想知道负载平衡是如何工作的。此 Web 服务有多个无状态实例:

提前致谢

Would each of them register with the Relay service?

Would I then have one Relay endpoint and many listeners behind it?

据我了解,由于您的 Web 服务在多个无状态实例下 运行,您可以在每个 Web 服务实例上构建 HybridConnectionListener 实例以获得更好的性能。正如这位官方 tutorial 所述 听众互动 :

The Hybrid Connections service endpoint allows up to 25 concurrent listeners on a Hybrid Connection.

How would the Relay service load balance?

正如 Interaction model 提到的关于听众互动:

If there are 2 or more active listeners, incoming connections will be balanced across them in random order; fair distribution is not guaranteed.