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: HTTPoison.Base.transformer #456

Merged
merged 1 commit into from
Mar 31, 2022

Conversation

Zarathustra2
Copy link
Contributor

Previously Process.monitor had been called in every recursion
for the target even though we only need to call it only once.

I observed that on production when using httpoison to consume server sent events. Noticed in the observer_cli:

httpoison_leak

I am currently using the PR code in production and it fixed the issue. Now also the blacked out processes to which I stream the server sent events ( so they are the target which has been monitored via Process.monitor(target) in the tranformer ) have a memory footprint of 8MB.

Previously `Process.monitor` had been called in every recursion
for the target even though we only need to call it only once.
@Zarathustra2 Zarathustra2 changed the title FIX: Memory leak: Monitor target only once FIX: Memory leak: HTTPoison.Base.transformer Mar 29, 2022
@edgurgel
Copy link
Owner

Thanks! Nice catch!

@edgurgel edgurgel merged commit a5484be into edgurgel:master Mar 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants