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
{{ message }}
This repository has been archived by the owner on Jul 5, 2020. It is now read-only.
We have rarely occurring issue, which lead to 100% CPU load.
When it happened again, we have made the process dump and used DebugDiag to find/diagnose the problem.
Here the result of the "Analysis report":
The following threads in w3wp.DMP are enumerating a System.Collections.Generic.Dictionary object:
Multiple threads enumerating through a collection is intrinsically not a thread-safe procedure. If the dictionary object accessed by these threads is declared as static then the threads can go in an infinite loop while trying to enumerate the dictionary if one of the threads writes to the dictionary while the other threads are reading\enumerating through the same dictionary. You may also experience High CPU during this stage. For more details refer to High CPU in .NET app using a static Generic.Dictionary
In our project on .NET 4.5 (ASP.NET Web-application for hosting WCF-service) used references to these NuGet-packages:
We have rarely occurring issue, which lead to 100% CPU load.
When it happened again, we have made the process dump and used DebugDiag to find/diagnose the problem.
Here the result of the "Analysis report":
The following threads in w3wp.DMP are enumerating a System.Collections.Generic.Dictionary object:
Multiple threads enumerating through a collection is intrinsically not a thread-safe procedure. If the dictionary object accessed by these threads is declared as static then the threads can go in an infinite loop while trying to enumerate the dictionary if one of the threads writes to the dictionary while the other threads are reading\enumerating through the same dictionary. You may also experience High CPU during this stage. For more details refer to High CPU in .NET app using a static Generic.Dictionary
All threads have a same call stack:
System.Collections.Generic.Dictionary
2[[System.__Canon, mscorlib],[System.__Canon, mscorlib]].FindEntry(System.__Canon)+1a6 System.Collections.Generic.Dictionary
2[[System.__Canon, mscorlib],[System.__Canon, mscorlib]].TryGetValue(System.__Canon, System.__Canon ByRef)+14Microsoft.ApplicationInsights.Extensibility.Implementation.LocationContext.get_Ip()+4f
Microsoft.ApplicationInsights.Web.ClientIpHeaderTelemetryInitializer.UpdateRequestTelemetry(System.Web.HttpContext, Microsoft.ApplicationInsights.Extensibility.Implementation.LocationContext)+199
Microsoft.ApplicationInsights.Web.ClientIpHeaderTelemetryInitializer.OnInitializeTelemetry(System.Web.HttpContext, Microsoft.ApplicationInsights.DataContracts.RequestTelemetry, Microsoft.ApplicationInsights.Channel.ITelemetry)+86
Microsoft.ApplicationInsights.Web.Implementation.WebTelemetryInitializerBase.Initialize(Microsoft.ApplicationInsights.Channel.ITelemetry)+86
Microsoft.ApplicationInsights.TelemetryClient.Initialize(Microsoft.ApplicationInsights.Channel.ITelemetry)+26e
Microsoft.ApplicationInsights.TelemetryClient.Track(Microsoft.ApplicationInsights.Channel.ITelemetry)+28
FIE.Common.Web.Code.ApplicationInsights.ApplicationInsightsLogExceptionAttribute.System.ServiceModel.Dispatcher.IErrorHandler.HandleError(System.Exception)+9b
System.ServiceModel.Dispatcher.ErrorBehavior.HandleErrorCommon(System.Exception, System.ServiceModel.Dispatcher.ErrorHandlerFaultInfo ByRef)+a7
System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessageCleanup(System.ServiceModel.Dispatcher.MessageRpc ByRef)+307
System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage9(System.ServiceModel.Dispatcher.MessageRpc ByRef)+e2
System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage8(System.ServiceModel.Dispatcher.MessageRpc ByRef)+ff
System.ServiceModel.Dispatcher.MessageRpc.ProcessError(System.Exception)+2c8
System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean)+169
[[HelperMethodFrame]]
System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(System.ServiceModel.Dispatcher.MessageRpc ByRef)+4e3
[[HelperMethodFrame]]
System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(System.ServiceModel.Dispatcher.MessageRpc ByRef)+764
[[HelperMethodFrame]]
The text was updated successfully, but these errors were encountered: