You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Like ShouldLogRequest is available for NLogRequestLoggingMiddleware, so one can downgrade LogLevel, then it should always be available for NLogRequestLoggingModule.
Maybe consider changing the logging so when LogLevel <= Info, then skip logging the exception. But just perform logging of the Exception.Type and Exception.Message (Ex. Input-Validation-Errors).
This could also be useful for ASP.NET Core, where HTTP 499 Client Closed Request together with TaskCanceledException should not be seen as "Error" (catch (OperationCanceledException) when (httpContext.RequestAborted.IsCancellationRequested))
The text was updated successfully, but these errors were encountered:
Like
ShouldLogRequest
is available forNLogRequestLoggingMiddleware
, so one can downgrade LogLevel, then it should always be available for NLogRequestLoggingModule.Maybe consider changing the logging so when LogLevel <= Info, then skip logging the exception. But just perform logging of the Exception.Type and Exception.Message (Ex. Input-Validation-Errors).
This could also be useful for ASP.NET Core, where
HTTP 499 Client Closed Request
together withTaskCanceledException
should not be seen as "Error" (catch (OperationCanceledException) when (httpContext.RequestAborted.IsCancellationRequested)
)The text was updated successfully, but these errors were encountered: