This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 87752 - Projects retained in memory by ProfilingSupport.attachProjectsCombo
Summary: Projects retained in memory by ProfilingSupport.attachProjectsCombo
Status: RESOLVED FIXED
Alias: None
Product: profiler
Classification: Unclassified
Component: Base (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Tomas Hurka
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2006-10-23 10:47 UTC by _ rkubacki
Modified: 2007-09-08 11:45 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ rkubacki 2006-10-23 10:47:54 UTC
dev build from Oct 20 + profiler build 061020, JDk6b98

I opened nbbuild+all projects, did few actions in IDE including opening profiler
TC and Attach profiler wizard and then closed everything but all project
instances and their associated data are held in memory (cannot get below 120MB
of used memory in Java heap).

The biggest problem seems to be this rerefence chain -

Static reference from
org.netbeans.modules.profiler.actions.ProfilingSupport.defaultInstance (from
class org.netbeans.modules.profiler.actions.ProfilingSupport) :
--> org.netbeans.modules.profiler.actions.ProfilingSupport@0xa8460640 (53 bytes)
(field attachProjectsCombo:)
--> javax.swing.JComboBox@0xa840d930 (364 bytes) (field accessibleContext:)
--> javax.swing.JComboBox$AccessibleJComboBox@0xa7b9e128 (76 bytes) (field
previousSelectedAccessible:)
--> javax.swing.JList$AccessibleJList$AccessibleJListChild@0xa18d0520 (56 bytes)
(field listModel:)
--> javax.swing.DefaultComboBoxModel@0xa163f9c0 (20 bytes) (field objects:)
--> java.util.Vector@0xa16664b8 (24 bytes) (field elementData:)
--> [Ljava.lang.Object;@0xa6af9810 (1288 bytes) (Element 62 of
[Ljava.lang.Object;@0xa6af9810:)
--> org.netbeans.modules.apisupport.project.NbModuleProject@0xa2d37c10 (36 bytes)
Comment 1 _ rkubacki 2006-10-23 10:53:45 UTC
These projects are probably released only if I open attach wizard again (and
model gets updated).
Comment 2 Tomas Hurka 2006-11-20 12:28:49 UTC
No, ProfilingSupport listens to OpenProjects.PROPERTY_OPEN_PROJECTS property change and updates 
model as soon as it receives this property change.
Comment 3 Tomas Hurka 2006-11-21 15:19:26 UTC
problem is that javax.swing.JList$AccessibleJList$AccessibleJListChild holds old DefaultComboBoxModel 
with opened projects. It does not listen to "model" property change and therefor do not reflect model 
change, when projects are closed. I will try to investigate if this is Swing bug.
Comment 4 Tomas Hurka 2007-01-08 10:32:51 UTC
Should be fixed in trunk.
Comment 5 Alexander Kouznetsov 2007-09-08 11:45:17 UTC
rkubacki, could you please verify this issue?