SignalR 组并不总是通信

SignalR Groups not always communicating

我在使用 SignalR 时遇到了一个奇怪的问题。这可能是我做错了什么或我的期望不正确。我已经在 git

上发布了示例代码和问题描述

https://github.com/boblautenbach/SignalRGroups

谢谢 -鲍勃

好的,所以我做了一些额外的研究。我找到了一个 SO q/a SignalR lost messages if IIS configure with more than 1 worker process that mentioned the same concerns and even though it wasn't related Azure, it was very relevant. If you have more than one instance of your Signalr hub Azure Web App, which can be set as seen below, then you will run into the issue I mentioned. Essentially, client connections made to instance A will not see instance B connections. If you do need more that one instance of your Hub, you will need to implement one of the scale-out options here http://www.asp.net/signalr/overview/performance/scaleout-in-signalr。我使用服务总线横向扩展选项对此进行了测试,效果很好(我的网站目前有 2 个实例)。