Microsoft.ApplicationInsights.Channel.InMemoryTransmitter.Runner()
Posted
技术标签:
【中文标题】Microsoft.ApplicationInsights.Channel.InMemoryTransmitter.Runner()【英文标题】: 【发布时间】:2020-03-27 01:11:27 【问题描述】:线程 xx - 系统 ID xxxxx 此线程在 WaitOne 中等待 入口点 clr!Thread::intermediateThreadProc
完整的调用堆栈
ntdll!ZwWaitForMultipleObjects+c
KERNELBASE!WaitForMultipleObjectsEx+f0
clr!WaitForMultipleObjectsEx_SO_TOLERANT+3c
clr!Thread::DoAppropriateWaitWorker+237
clr!Thread::DoAppropriateWait+64
clr!WaitHandleNative::CorWaitOneNative+163
mscorlib_ni!System.Threading.WaitHandle.InternalWaitOne(System.Runtime.InteropServices.SafeHandle, Int64, Boolean, Boolean)+21
mscorlib_ni!System.Threading.WaitHandle.InternalWaitOne(System.Runtime.InteropServices.SafeHandle, Int64, Boolean, Boolean)+21
mscorlib_ni!System.Threading.WaitHandle.WaitOne(System.TimeSpan, Boolean)+60
mscorlib_ni!System.Threading.WaitHandle.WaitOne(System.TimeSpan, Boolean)+60
mscorlib_ni!System.Threading.WaitHandle.WaitOne(System.TimeSpan)+17
mscorlib_ni!System.Threading.WaitHandle.WaitOne(System.TimeSpan)+17
+7b
mscorlib_ni!System.Threading.Tasks.Task.InnerInvoke()+28
mscorlib_ni!System.Threading.Tasks.Task.Execute()+30
我在 azure 内存转储分析中发现内存泄漏。你能告诉我我错过了什么吗?我正在使用 .Net 4.6.1 框架和 application-insight 2.11.0.0
【问题讨论】:
您是如何意识到这是内存泄漏的?.. @ArtemRazin 我们针对 Azure 应用服务运行了内存转储。在分析师中,它提到线程正在 WaitMultiple 中等待 【参考方案1】:这是等待遥测数据发送的应用洞察通道。在批量发送遥测数据之前,通道会等待多个项目或经过一定时间。它的存在本身并不是真正的“泄漏”,但它可能取决于“泄漏”的定义以及通道在发送项目之前缓冲项目的时间。
如果您认为这是一个真正的泄漏,最好的报告速度是在 .net sdk 的 github 中:
https://github.com/Microsoft/ApplicationInsights-dotnet/issues
【讨论】:
感谢 cmets。我已经提出了一个问题,他们没有回应。朋友,github.com/microsoft/ApplicationInsights-dotnet/issues/1332以上是关于Microsoft.ApplicationInsights.Channel.InMemoryTransmitter.Runner()的主要内容,如果未能解决你的问题,请参考以下文章