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 related to MerginProject object #79

Merged
merged 1 commit into from
Oct 18, 2022

Conversation

wonder-sk
Copy link
Contributor

Fixes #78

It turns out that we are creating MerginProject objects way too much, and the cleanup of it may not be handled properly because of a cyclic reference between MerginProject and its internal GeoDiff context object.

It is going to be both safer and faster to create MerginProject for a particular working directory once and then keep it cached.

Fun fact: the leak is not showing up in "top" commend, only in docker's stats about memory...

It turns out that we are creating MerginProject objects way too much,
and the cleanup of it may not be handled properly because of a cyclic
reference between MerginProject and its internal GeoDiff context object.

It is going to be both safer and faster to create MerginProject for
a particular working directory once and then keep it cached.

Fun fact: the leak is not showing up in "top" commend, only in
docker's stats about memory...
@wonder-sk wonder-sk requested a review from alexbruy October 17, 2022 22:01
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.

Memory consumption keeps increasing
2 participants