-
Notifications
You must be signed in to change notification settings - Fork 286
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Potential memory leak of DiagnosticListener - .NET Framework app on Azure App Service #2033
Comments
This issue is stale because it has been open 300 days with no activity. Remove stale label or comment or this will be closed in 7 days. |
Yes, good tactic. Sad world. |
Hello @jirikanda, I'm sorry this issue was overlooked when it was opened. Do you have a repro for this issue? This would help us investigate and collect more data. If not, you can create an Azure Support Request and one of our engineers can help collect a dump from your environment. |
From a quick look, it looks like a code issue as it shows many instances of TelemetryClient itself. Please share the code snippet used to enable application insights, and we can review if it is correct. |
To be honest, we have mitigated the issue. But be sure there is no code which is creating a new TelemetryClient instance. It is hidden somewhere in the Application Insights packages. But what we did was creating a lot of Azure Blob Storage Client (BlobContainerClient) instances. When we change this behavior to have BlobContainerClient singleton, the issue was mitigated. I am not going to provide any snippet after a year. I also did not checked if the issue with BlobContainerClient was mitigated in the library. Hope, you are not solving the issue as "not out team issue" on both sides. |
I am creating a separate issue from #1867 to better target issue to the .NET Framework.
Environment
What is the expected behavior?
GC able to reclaim memory.
What is the actual behavior?
Number of DiagnosticSubscriptions grows in time.
The are two images below:
The text was updated successfully, but these errors were encountered: