When FbWebSocket is reconnecting and FbClient.CloseAsync is called, e.g. when FbClientHostedService is stopped during service shut down, ShuttingDownWithError is logged as an error.
This happens after it has already been logged by ReconnectingStoppedDuringRetryDelay (info) or ReconnectingStoppedDuringReconnectAttempt (warning).
It seems like if it was shutting down gracefully, it should not log an error about what it was in the middle of doing at the time, as it's not really terminating with an error, it has been stopped by the caller.
We sometimes get a spike of errors in our logs when we deploy a new version of a service and the old replicas get shut down.
Would it be possible to avoid logging this error in these cases?
When
FbWebSocketis reconnecting andFbClient.CloseAsyncis called, e.g. whenFbClientHostedServiceis stopped during service shut down,ShuttingDownWithErroris logged as an error.This happens after it has already been logged by
ReconnectingStoppedDuringRetryDelay(info) orReconnectingStoppedDuringReconnectAttempt(warning).It seems like if it was shutting down gracefully, it should not log an error about what it was in the middle of doing at the time, as it's not really terminating with an error, it has been stopped by the caller.
We sometimes get a spike of errors in our logs when we deploy a new version of a service and the old replicas get shut down.
Would it be possible to avoid logging this error in these cases?