-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Sentry upgrade from 7.118.0 to 8.26.0 leak memory #13412
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
Comments
Hey @flav-code thanks for writing in! We'll look into your issue next week as this week is Hackweek at Sentry (see #13421). |
Hi, @flav-code would you be able to provide a memory snapshot with the Node/v8 profiler so that we can look at what is holding the references causing the leak? Feel free to also shoot us an email or twitter dm if you don't want to publicly share it. Thanks! |
I can't give you an snapshot because I have a lot of private information. |
I made a snapshot, I'll examine it and show you |
Set, Span and NonRecordingSpan are from Sentry |
Yeah that looks like Sentry. Would you mind digging around a bit ant examine what holds the references to the spans? |
This indicates that Sentry objects are retained in memory. It doesn't mean they are causing this retention though! |
|
I don't think so. Before switching to sentry v8, someone warned me about the memory leak. |
I have a few questions to narrow this down further. I am not ruling out that our SDK is causing the leak:
|
That setup looks good 👌 Can you share more of the debug logs? It would be good to see logs up until and including when you do things like send requests and database queries and similar. Thanks! |
Would you mind sharing the start of your application up to a certain point in text format? Thanks! |
Do you have discord ? |
Yes! Feel free to join https://discord.com/invite/sentry and ping |
After some back and fourth we have discovered that the memory leak in this issue happens due to the The workaround for now is to do the following: Sentry.init({
integrations: [
Sentry.httpIntegration({
ignoreOutgoingRequests(url, request) {
return true;
},
}),
],
}) Thanks for the collaboration @flav-code!! Action items (varying degrees of possible):
|
No problem 👍 |
Hey, I am closing this because I believe we found the issue and provided a workaround for the time being. Please re-open if you still encounter the problem - thank you! |
yes, it's not as bad as before |
Note that this is one of the cases that will be solved once we switch to span streaming. So in like 5 years. |
5 years ??? |
I should have added a sarcasm indicator 😬 It's coming but it's taking longer than we (I) would like. Hopefully sooner than 5 years. |
Is there an existing issue for this?
How do you use Sentry?
Self-hosted/on-premise
Which SDK are you using?
@sentry/node
SDK Version
8.26.0
Framework Version
No response
Link to Sentry event
No response
Reproduction Example/SDK Setup
my sentry init in 7.118.0
my sentry init in 8.6.0
Steps to Reproduce
I'll try removing some of the integrations to see what's causing the problem.
Expected Result
A normal memory usage
Actual Result
anormal memory usage
The text was updated successfully, but these errors were encountered: