mirror of
https://github.com/Caraxi/mare.server.git
synced 2025-12-16 21:54:21 +01:00
log exception OnDisconnectAsync
This commit is contained in:
parent
54d625e729
commit
c21e2f740c
1 changed files with 5 additions and 1 deletions
|
|
@ -94,6 +94,11 @@ public class SignalRLimitFilter : IHubFilter
|
||||||
HubLifetimeContext context, Exception exception, Func<HubLifetimeContext, Exception, Task> next)
|
HubLifetimeContext context, Exception exception, Func<HubLifetimeContext, Exception, Task> next)
|
||||||
{
|
{
|
||||||
await DisconnectLimiterSemaphore.WaitAsync();
|
await DisconnectLimiterSemaphore.WaitAsync();
|
||||||
|
if (exception != null)
|
||||||
|
{
|
||||||
|
logger.LogWarning(exception, "InitialException on OnDisconnectedAsync");
|
||||||
|
}
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
await next(context, exception);
|
await next(context, exception);
|
||||||
|
|
@ -101,7 +106,6 @@ public class SignalRLimitFilter : IHubFilter
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
logger.LogWarning(exception, "InitialException on OnDisconnectedAsync");
|
|
||||||
logger.LogWarning(e, "ThrownException on OnDisconnectedAsync");
|
logger.LogWarning(e, "ThrownException on OnDisconnectedAsync");
|
||||||
}
|
}
|
||||||
finally
|
finally
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue