ClientWebSocket.Connect
hangs indefinitely if using HttpVersionPolicy.RequestVersionOrHigher
on wss connections
#111977
Labels
Milestone
Description
ClientWebSocket
hangs when attempting to connect to HTTP/1.1 WebSocket server usingRequestVersionOrHigher
policy. If this is expected behavior, it should probably be documented.Reproduction Steps
This will hang unless
HttpVersionPolicy
setting is commented out:Expected behavior
Correctly determining that server doesn't support HTTP/2 and falling back to HTTP/1.1.
Actual behavior
Hangs indefinitely.
Regression?
Didn't test on .NET 7 yet, but seems to behave similarly on .NET 8 and .NET 9.
Known Workarounds
Using inverse options seems to work:
Configuration
Tested on .NET 8, 9: win-x64, linux-x64, linux-arm64.
Other information
No response
The text was updated successfully, but these errors were encountered: