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.
[recent build] There appear to be a massive leak related to per-project libraries. In the heap dump, there are >1000000 instances of Library, WeakReference and related classes. There are also more than 100000 instances of LibraryManager. The problem IMO is that: LibraryManagers are being constructed when needed (e.g. by LibraryManager.getOpenManagers()), but not cached. Each library manager non-weakly listens on a LibraryProvider and it also holds the LibraryProvider instance. But the LibraryProviders are weakly-cached at their creation. So one LibraryManager that is being held (e.g. by a query result which is listening on it) holds the LibraryProvider and through the listeners all LibraryManagers that were created for the same LibraryProvider, which is causing the leak. I am going to change the LibraryManager to listen only weakly on the LibraryProvider.
http://hg.netbeans.org/jet-main/rev/44968f0c0f27
Integrated into 'main-golden', will be available in build *201008270001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/44968f0c0f27 User: Jan Lahoda <jlahoda@netbeans.org> Log: #189880: LibraryManager listens only weakly on the LibraryProvider to prevent leaks.