1 year ago
#369680
Mhaz2000
The I/O operation has been aborted because of either a thread exit or an application request while trying to connect signalR endpoint through yarp
I am trying to connect signalR endpoint using Yarp as a reverse proxy.
However I faced this error:
The yarp configuration is:
"ReverseProxy": {
"Clusters": {
"ws-cluster": {
"Destinations": {
"ws-destination1": {
"Address": "http://localhost:8240"
}
}
}
},
"Routes": {
"dev-ws": {
"ClusterId": "ws-cluster",
"CorsPolicy": "any",
"Match": {
"Path": "ws/{**catch-all}"
}
}
}
}
and the signalR endpoint is:
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
{
if (env.IsDevelopment())
{
app.UseDeveloperExceptionPage();
}
app.UseAuthentication();
app.UseRouting();
app.UseCors(MyAllowSpecificOrigins);
app.UseAuthorization();
app.UseEndpoints(endpoints =>
{
endpoints.MapHub<HubService>("/ws");
endpoints.MapControllers().RequireCors(MyAllowSpecificOrigins);
});
}
And there is something strange about the gateway, when I call ws://localhost:8000/ws
(The gateway has been hosted on port 8000) inside the server, it works! but if I use its domain
from outside of the server it won't!
Is there a problem with IIS or do I need to apply a specific configuration?
iis
signalr
reverse-proxy
gateway
ms-yarp
0 Answers
Your Answer