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 36436 - Memory leak running "Javadoc" wrapper script
Summary: Memory leak running "Javadoc" wrapper script
Status: VERIFIED WORKSFORME
Alias: None
Product: projects
Classification: Unclassified
Component: Ant (show other bugs)
Version: 3.x
Hardware: PC Linux
: P3 blocker (vote)
Assignee: issues@projects
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2003-10-04 22:24 UTC by Jesse Glick
Modified: 2005-07-15 07:43 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Problematic script (867 bytes, text/xml)
2003-10-04 22:24 UTC, Jesse Glick
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jesse Glick 2003-10-04 22:24:01 UTC
Try the attached build script. (Change ${base} as
needed.) Every time I run it, I get an approx.
10Mb heap leak.

This is after correcting various other Ant-related
leaks. Seems to leak with both Ant 1.5.3 and 1.6 beta.

You can look at the heap using a profiler after
running the script. It has a bunch of instances of
Project, and associated tasks and types and so on.
The main Project ("Current API &Javadoc") is
not among them - just subprojects.

Both HAT and OptimizeIt display the stray
instances. But neither show any references from
persistent roots. I cannot track down why the
object graphs are being held.

It seems that running trivial Ant scripts do not
leak this way. In fact, I tried (under a profiler)
running the three subcomponents of the wrapper
script by themselves, as well as the run-nb target
(without a dep on the run target), and in all
cases the Project graph was collected. But running
the whole script reproducibly leaks.
Comment 1 Jesse Glick 2003-10-04 22:24:58 UTC
Created attachment 11794 [details]
Problematic script
Comment 2 Jesse Glick 2003-10-04 22:28:22 UTC
Huh, never mind. The objects *do* get released - several minutes
later. Just pressing GC twenty times doesn't do it; you have to wait.
Perhaps some of the objects got stuck into an older GC generation and
didn't get cleaned out easily?
Comment 3 Marian Mirilovic 2005-07-15 07:43:22 UTC
closed