Project

General

Profile

Actions

Bug #1131

closed

closing datapackage windows does not release memory

Added by Dan Higgins over 20 years ago. Updated over 20 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
morpho - general
Target version:
Start date:
08/15/2003
Due date:
% Done:

0%

Estimated time:
Bugzilla-Id:
1131

Description

Creating a new datapackage display window can use a lot of memory. Observation
of memory usage indicates that the JRE memory used when the window is created
does not seem to be released when the window is closed. This may cause
out-of-memory problems as many windows are opened and closed.

Actions #1

Updated by Dan Higgins over 20 years ago

Note that the Window.dispose() method was used when a window was closed to
recover memory. However, the documentation for dispose says

"Releases all of the native screen resources used by this Window, its
subcomponents, and all of its owned children. That is, the resources for these
Components will be destroyed, any memory they consume will be returned to the
OS, and they will be marked as undisplayable.

The Window and its subcomponents can be made displayable again by rebuilding the
native resources with a subsequent call to pack or show. The states of the
recreated Window and its subcomponents will be identical to the states of these
objects at the point where the Window was disposed (not accounting for
additional modifications between those actions). "

Note that only 'native screen resources' is recovered. It appears that various
java objects associated with a window (e.g a treesub panels, trees, etc.) are
NOT destroyed and their memory not automatically recovered! (or they could not
be recovered with a call to pack or show).

Actions #2

Updated by Dan Higgins over 20 years ago

Several changes made to 'force' the release of memory when a window is closed.
These seem to have solved the memory leak problems noted here.

Actions #3

Updated by Redmine Admin about 11 years ago

Original Bugzilla ID was 1131

Actions

Also available in: Atom PDF