You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
puppy => You're not submitting a puppy. I already have one and he's adorable
What is the current behavior?
Android Studio team noticed memory reports from our users, where gitflow leaks objects related to projects that has already been closed.
Is this a bug? Sorry about that. If so give me explicit details how to reproduce:
Open Android Studio
Open a project
Close the project
Reopen same project
Inspect heap in a profiler: the instance of ProjectImpl of the closed project is kept alive due to gitflow plugin.
What is the expected behavior?
gitflow should not store references to large objects like ProjectImpl after the project has been closed. Depending on what the ProjectImpl references, the memory leak can be from 20MB to over 100MB.
What is the motivation / use case for changing the behavior?
Lower memory consumption of gitflow plugin in Android Studio.
Please tell me about your environment:
Gitflow4idea version: 0.7.0
Reproduced on Android Studio 4.0 Canary 1, likely affects all versions of Android Studio and IntelliJ Idea.
Other information (e.g. detailed explanation, stacktrace, related issues, suggestions how to fix, links for me to have context words of praises, pictures of puppies (again with the puppy??) )
In the report above, the memory leak is ~60MB. For some projects it can be even more and a new leak happens every time a project is closed.
GitflowConfigUtil.gitflowConfigUtilMap uses ProjectImpl as a key in the map and GitflowBranchUtilManager.repoBranchUtilMap uses GitRepositoryImpl instance as a key, Neither of the maps removes the reference when project is closed.
For entries in repoBranchUtilMap, consider adding a following code inGitflowBranchUtilManager.setupBranchUtil:
I'm submitting a ...
What is the current behavior?
Android Studio team noticed memory reports from our users, where gitflow leaks objects related to projects that has already been closed.
Is this a bug? Sorry about that. If so give me explicit details how to reproduce:
ProjectImpl
of the closed project is kept alive due to gitflow plugin.What is the expected behavior?
gitflow should not store references to large objects like
ProjectImpl
after the project has been closed. Depending on what theProjectImpl
references, the memory leak can be from 20MB to over 100MB.What is the motivation / use case for changing the behavior?
Lower memory consumption of gitflow plugin in Android Studio.
Please tell me about your environment:
Reproduced on Android Studio 4.0 Canary 1, likely affects all versions of Android Studio and IntelliJ Idea.
Other information (e.g. detailed explanation, stacktrace, related issues, suggestions how to fix, links for me to have context words of praises, pictures of puppies (again with the puppy??) )
Relevant part of a memory report:
In the report above, the memory leak is ~60MB. For some projects it can be even more and a new leak happens every time a project is closed.
GitflowConfigUtil.gitflowConfigUtilMap
usesProjectImpl
as a key in the map andGitflowBranchUtilManager.repoBranchUtilMap
usesGitRepositoryImpl
instance as a key, Neither of the maps removes the reference when project is closed.For entries in
repoBranchUtilMap
, consider adding a following code inGitflowBranchUtilManager.setupBranchUtil
:For
gitflowConfigUtilMap
, consider similar pattern or useProjectManagerListener.projectClosed
event to remove the key from the map.The text was updated successfully, but these errors were encountered: