Skip to content
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

fix memory leak in http plugin when sockets are reused #210

Merged
merged 2 commits into from
Aug 1, 2018

Conversation

rochdev
Copy link
Member

@rochdev rochdev commented Aug 1, 2018

This PR fixes a memory leak in the http plugin when sockets are reused for multiple requests, for example when setting keepAlive to true. Since an event handler was attached to the socket directly and never removed for every request, they would slowly add up for the life of the socket.

The fix also has the additional benefit that the span will no longer finish early if the connection is closed before all data has been consumed.

Fixes #206

@rochdev rochdev added bug Something isn't working integrations labels Aug 1, 2018
@rochdev rochdev added this to the 0.5.3 milestone Aug 1, 2018
vinvol
vinvol previously approved these changes Aug 1, 2018
@rochdev rochdev merged commit e92a0d6 into master Aug 1, 2018
@rochdev rochdev deleted the fix-http-memory-leak branch August 1, 2018 20:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working integrations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Errors when using with Firebase
2 participants