Memory leak when switching projects

The memory leak with switching projects is caused by plugins you are
using, they just have strong references to the projects (most often as
keys in the map) thus causing the memory leak.
Following example plugin classes from the snapshot strongly reference
the Project:
- SQLPluginPanel (SQLPlagin) has field instanceMap of type
- org.rafke.RSSPanel has field instances of type HashMap<Project,?>
- netx.trustx.simpleuml.components.DiagramSettingsWorkspace (simpleuml)
has field DiagramSettingsWorkspaceMap field of type HashMap<Project,?>
- com.propertyEditor.propedit.model.bundle.BundleManager
(PropertyEditor) has field managers with type HashMap<Project,?>
- tmate classes also have references to Project, exact classes/fields
are ommitted due to unreadability after obfuscation

To plugin writers, always clear reference to projects you are using on
closing the project (Project components has callbacks on close project,
ProjectManager has listener subscription for projects lifecycle)

Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
"Develop with pleasure!"

1 comment
Comment actions Permalink

For PropertiesEditor plugin fixed in this place but looks like some leak due PE remains, I'll take YJP and investigate problems more carefully.



Please sign in to leave a comment.