From e2e787261d63190b615c03defa47001fd6553501 Mon Sep 17 00:00:00 2001 From: "kay.one" Date: Sat, 14 Sep 2013 12:59:06 -0700 Subject: [PATCH] don't log signalr heartbeat exceptions as EPIC FAIL. --- .../Instrumentation/GlobalExceptionHandlers.cs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/NzbDrone.Common/Instrumentation/GlobalExceptionHandlers.cs b/NzbDrone.Common/Instrumentation/GlobalExceptionHandlers.cs index 20a076b58..ed32997eb 100644 --- a/NzbDrone.Common/Instrumentation/GlobalExceptionHandlers.cs +++ b/NzbDrone.Common/Instrumentation/GlobalExceptionHandlers.cs @@ -21,6 +21,15 @@ namespace NzbDrone.Common.Instrumentation private static void AppDomainException(Exception exception) { + if (exception == null) return; + + if (exception is NullReferenceException && + exception.ToString().Contains("Microsoft.AspNet.SignalR.Transports.TransportHeartbeat.ProcessServerCommand")) + { + Logger.Warn("SignalR Heartbeat error."); + return; + } + Console.WriteLine("EPIC FAIL: {0}", exception); Logger.FatalException("EPIC FAIL: " + exception.Message, exception); }