79628281

Date: 2025-05-19 07:34:52
Score: 0.5
Natty:
Report link

Thanks for the input @buymeacoffee that’s a great point. ISP-level filtering can definitely affect WebSocket connectivity, especially across borders into Azure China. If this is suspected, raising a support ticket via the Azure portal is a good next step so Azure’s network team in Asia can analyze traces and confirm whether the issue is routing- or ISP-related.

That said, this issue is also commonly tied to the network separation between Azure China (21Vianet) and the global Azure cloud. Azure China enforces strict cross-border traffic controls, and WebSocket connections are often unreliable when accessed from outside China.

Browse the website using Chrome from OUTSIDE China (WebSockets fail, but long polling works)

This usually works because the browser silently falls back to long polling. However, Node.js clients won’t do that unless explicitly configured. Check that your SignalR client allows transport fallback:

const connection = new signalR.HubConnectionBuilder()
  .withUrl("/chatHub", {
    transport: signalR.HttpTransportType.WebSockets | signalR.HttpTransportType.LongPolling
  })
  .build();

Also check your CORS and TLS settings Node clients are stricter and will fail on misconfigured policies that browsers might tolerate.

enter image description here

Unfortunately, even with fallback, you will still run into issues connecting to Azure China from outside. For production scenarios, I’d recommend mirroring the backend in global Azure and routing users regionally using Azure Traffic Manager.

Reasons:
  • Blacklisted phrase (0.5): Thanks
  • Long answer (-1):
  • Has code block (-0.5):
  • User mentioned (1): @buymeacoffee
  • Low reputation (0.5):
Posted by: Harish Bodapati