Make sure idle disconnects are not logged to app insights.

This commit is contained in:
Burak Kaan Köse
2025-02-16 16:14:50 +01:00
parent d36cf59829
commit db833594f4

View File

@@ -723,12 +723,12 @@ public class ImapSynchronizer : WinoSynchronizer<ImapRequest, ImapMessageCreatio
} }
catch (ImapProtocolException protocolException) catch (ImapProtocolException protocolException)
{ {
Log.Warning(protocolException, "Idle client received protocol exception."); Log.Information(protocolException, "Idle client received protocol exception.");
reconnect = true; reconnect = true;
} }
catch (IOException ioException) catch (IOException ioException)
{ {
Log.Warning(ioException, "Idle client received IO exception."); Log.Information(ioException, "Idle client received IO exception.");
reconnect = true; reconnect = true;
} }
catch (OperationCanceledException) catch (OperationCanceledException)
@@ -737,7 +737,7 @@ public class ImapSynchronizer : WinoSynchronizer<ImapRequest, ImapMessageCreatio
} }
catch (Exception ex) catch (Exception ex)
{ {
Log.Warning(ex, "Idle client failed to start."); Log.Error(ex, "Idle client failed to start.");
reconnect = false; reconnect = false;
} }
finally finally