WebSockets connection fails if UpstreamPathTemplate doesn't point to /
and contains {everything}
#1947
eddex
started this conversation in
Show and tell
Replies: 2 comments 1 reply
-
I did some further testing and found that this configuration also works: {
"UpstreamPathTemplate": "/ws-echo/",
"DownstreamPathTemplate": "/",
"DownstreamScheme": "wss",
"DownstreamHostAndPorts": [
{
"Host": "echo.websocket.org",
"Port": 443
}
]
}, This doesn't work: {
"UpstreamPathTemplate": "/ws-echo/{everything}",
"DownstreamPathTemplate": "/",
"DownstreamScheme": "wss",
"DownstreamHostAndPorts": [
{
"Host": "echo.websocket.org",
"Port": 443
}
]
}, And this doesn't work either: {
"UpstreamPathTemplate": "/ws-echo/",
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "wss",
"DownstreamHostAndPorts": [
{
"Host": "echo.websocket.org",
"Port": 443
}
]
}, |
Beta Was this translation helpful? Give feedback.
1 reply
-
When using the |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Expected Behavior
UpstreamPathTemplate
can be changed to any path that should be used for the websockets connectionActual Behavior
UpstreamPathTemplate
"/{everything}" the websockets connection worksUpstreamPathTemplate
that doesn't contain "{everything}" the websockets connection works tooUpstreamPathTemplate
that contains "{everything}" doesn't workSteps to Reproduce the Problem
wsUri
to point to the local ocelot instance. Example:wss://localhost:44338/
.UpstreamPathTemplate
to "/ws-echo/{everything}":wsUri
in the HTML file to reflect the changes. Example:wss://localhost:44338/ws-echo/
.Specifications
Beta Was this translation helpful? Give feedback.
All reactions