-
-
Notifications
You must be signed in to change notification settings - Fork 213
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
Memory Leak when using Sentry Profiling #3407
Comments
Hey @Skyppid, thanks for reaching out. Do you have a repro-sample for us to easily reproduce this? |
It's literally just the ASP.Net API template with Sentry added. Add some DSN if even necessary and run it. It'll leak constantly. EDIT: Seems to be only related to Profiling - Sampling seems to working without leaks. |
I can confirm huge memory problems with profiling in .NET in general too. We've activated it for our testing system and memory went through the roof while at the same time responses were incredibly slow. |
It looks like we've got duplicate issues going on regarding memory consumption/leak and CPU requirements. I'm closing this in favor of #3199 |
Package
Sentry
.NET Flavor
.NET
.NET Version
8.0.6
OS
Windows
SDK Version
4.7.0
Self-Hosted Sentry Version
No response
Steps to Reproduce
Enable profiling like this in the
UseSentry
configuration delegate:Run app and wait. It constantly leaks memory even if no requests occur at all.
Expected Result
No memory leak
Actual Result
As you see the app is completely idle. No requests happening. App just started and did nothing yet. Constantly increases memory.
On our staging cluster the app scaled to 10 pods in only a few minutes due to the memory leak.
Disabling the profiling fixes the problem.
Further data:


As you can see the memory constantly grows. The snapshots show the difference between when the app is fully started and ~2 minutes of idle.
EDIT: This screenshot is after 50m of idle runtime.

The text was updated successfully, but these errors were encountered: