-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Mastodon Memory Leak #225
Comments
Argh the horror. |
The following few lines of code are enough to trigger an OutOfMemoryException: package org.mastodon.mamut.tomancak;
import org.junit.Test;
import org.mastodon.mamut.model.Model;
public class MastodonMemoryTest
{
@Test
public void test() {
for ( int i = 0; i < 100; i++ )
{
new Model();
}
}
} The problem seems to be related to the UndoRedoStack. See stack trace:
|
…g tests. This is necessary, since there is a memory leak in mastodon (mastodon-sc/mastodon#225)
…g tests. This is necessary, since there is a memory leak in mastodon (mastodon-sc/mastodon#225)
This is necessary, since there is a memory leak in mastodon (mastodon-sc/mastodon#225)
This is necessary, since there is a memory leak in mastodon (mastodon-sc/mastodon#225)
@maarzt Could you ask for review/approval/merge of the related PR bigdataviewer/bigdataviewer-core#163 so that the temporarily introduced PainterThread of this PR does not live longer than necessary? |
I'll review it today |
merged and released with bigdataviewer-core-10.4.7 |
Could we depend on bigdataviewer-core-10.4.7 in mastodon and use the code from there? Or do we have specifics in Mastodon? |
This issue if fixed with the following PRs being merged and mastodon-graph-1.0.0-beta-24 and bigdataviewer-core-10.4.7 being released: |
Hello @maarzt Unfortunately I tested the
|
Problem description
I noticed that mastodon objects like WindowManger, ProjectManager, AppModel etc. don't get garbage collected after the project is closed.
This can be a problem for users. Fiji might run out of memory when opening a large number of Mastodon projects, one after the other. The Eclipse Memory Analyzer is a handy tool to inspect such problems. The
org.mastodon.spatial.SpatioTemporalIndexImpRebuilderThread
seems to stay in memory and keeps a reference to the ModelGraph.TODOs
Expected Behavior
All Mastodon related objects (WindowManager, ProjectManager, AppModel, ModelGraph, etc. ) get garbage collected after a Mastodon project is closed.
The text was updated successfully, but these errors were encountered: