Azure / azure-signalr

Azure SignalR Service SDK for .NET
https://aka.ms/signalr-service
MIT License
427 stars 101 forks source link

IUserIdProvider.GetUserId(HubConnectionContext connection) calls not going through middlewares #1698

Closed co-dax closed 1 year ago

co-dax commented 2 years ago

IUserIdProvider.GetUserId(HubConnectionContext connection) calls are being called by Azure SignalR server in which case they are not going through middlewares. I need them to go through the middlawares as I am extracting some data from connection url query string so that I can figure out SignalR connection id needed as the result of the call to IUserIdProvider.GetUserId(HubConnectionContext connection). As a workaround I can do(that is, repeat) the job from the middleware in the method IUserIdProvider.GetUserId(HubConnectionContext connection) but it might be the case to make calls from AzureSignalR directed to IUserIdProvider.GetUserId(HubConnectionContext connection) to go through the middlewares as it is the case when not using Azure SignalR service.

By the way the calls to the method IUserIdProvider.GetUserId(HubConnectionContext connection) are only sporadically made from Azure SignalR service.

Y-Sindo commented 2 years ago

What do you mean by "going through middlewares"? A reproducible program is better to demonstrate your expected behaviour.

vicancy commented 1 year ago

Please feel free to reopen the issue if there are updates