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.
I ran sunstudio script from the cmdline (based on NB6.9rc2). I did a remote build, and a remote debug. Then I exited the IDE using File->Exit. The sunstudio script never returned back to the shell. A ^\ yielded this: "AWT-EventQueue-1" prio=3 tid=0x00511400 nid=0x1d sleeping[0xf7efe000..0xf7effac0] java.lang.Thread.State: RUNNABLE at sun.nio.ch.FileChannelImpl.size0(Native Method) at sun.nio.ch.FileChannelImpl.size(FileChannelImpl.java:312) - locked <0xb7f107e0> (a java.lang.Object) at org.netbeans.modules.cnd.repository.sfs.BufferedRWAccess.size(BufferedRWAccess.java:152) at org.netbeans.modules.cnd.repository.sfs.IndexedStorageFile.write(IndexedStorageFile.java:149) - locked <0xb7ef9470> (a org.netbeans.modules.cnd.repository.sfs.IndexedStorageFile$Lock) at org.netbeans.modules.cnd.repository.sfs.DoubleFileStorage.write(DoubleFileStorage.java:149) at org.netbeans.modules.cnd.repository.disk.UnitImpl.putPhysically(UnitImpl.java:153) at org.netbeans.modules.cnd.repository.disk.DiskRepositoryManager.write(DiskRepositoryManager.java:168) at org.netbeans.modules.cnd.repository.disk.DiskRepositoryManager.closeUnit2(DiskRepositoryManager.java:281) at org.netbeans.modules.cnd.repository.disk.DiskRepositoryManager.closeUnit(DiskRepositoryManager.java:270) - locked <0xb68b6e10> (a org.netbeans.modules.cnd.repository.disk.DiskRepositoryManager$NamedLock) at org.netbeans.modules.cnd.repository.impl.DelegateRepository.closeUnit(DelegateRepository.java:118) at org.netbeans.modules.cnd.modelimpl.repository.RepositoryUtils._closeUnit(RepositoryUtils.java:315) at org.netbeans.modules.cnd.modelimpl.repository.RepositoryUtils.closeUnit(RepositoryUtils.java:302) at org.netbeans.modules.cnd.modelimpl.repository.RepositoryUtils.closeUnit(RepositoryUtils.java:292) at org.netbeans.modules.cnd.modelimpl.csm.core.ProjectBase.dispose(ProjectBase.java:2027) at org.netbeans.modules.cnd.modelimpl.csm.core.ModelImpl.disposeProject(ModelImpl.java:310) at org.netbeans.modules.cnd.modelimpl.csm.core.ModelImpl.disposeProject(ModelImpl.java:297) at org.netbeans.modules.cnd.modelimpl.csm.core.ModelImpl.shutdown(ModelImpl.java:462) at org.netbeans.modules.cnd.modelimpl.platform.ModelSupport.shutdown(ModelSupport.java:185) at org.netbeans.modules.cnd.modelimpl.Installer.close(Installer.java:72) at org.netbeans.core.startup.NbInstaller.close(NbInstaller.java:696) at org.netbeans.ModuleManager.shutDown(ModuleManager.java:1619) at org.netbeans.core.startup.ModuleSystem.shutDown(ModuleSystem.java:308) at org.netbeans.core.NbLifecycleManager.doExit(NbLifecycleManager.java:167) at org.netbeans.core.NbLifecycleManager.access$000(NbLifecycleManager.java:75) at org.netbeans.core.NbLifecycleManager$ExitActions.run(NbLifecycleManager.java:123) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) at java.awt.EventQueue.dispatchEvent(EventQueue.java:597) at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:137) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160) at java.awt.EventDispatchThread.run(EventDispatchThread.java:121) A complete dump will follow.
Created attachment 99832 [details] full dump of hung IDE
It turns out that it's not a hang, merely a very long shutdown. what might be contributing is that I also have a large project open (dbx). But I am debugging a separate smaller project. I wait til the IDE has parsed the big project and run "checking for external changes" before I exit. And then I see the hang ... which eventually terminates.
see also bug #186897
(In reply to comment #3) > see also bug #186897 bug #186897 has been closed as a duplicate of bug #186655 the focus of which is to improve the scan time. This bug however brings up the need for terminating a scan that is no longer needed (or maybe making sure it isn't even started).
I can reproduce bug on sun ray (sr1-espb04-03): Prepare to experiment: - copy netbeans (development version) in the home directory - start IDE - add OracleSolarisStudio from /shared/dp/sstrunk/build27.0 - create project from existing code (I have mySQL 5.1.30), tool OracleSolarisStudio - wait finishing parsing - close project - exit from IDE Steps to reproduce bug: - clear cnd cache - start IDE - d-n-d mysql-5.1.30/sql/mysqld into editor area - create project - wait finishing parsing - delete project with sources - exit IDE Actual: IDE is not finishing for 3 minutes. Expected: IDE is finishing for 3 seconds.
It should be investigated who starts "checking for external changes" for the just closed project and reassigned to platform if it's a bug in NB projects infrastructure.
Created attachment 100118 [details] my thread dump
fixed in cnd-main, change set: http://hg.netbeans.org/cnd-main/rev/488bd1111b6d Vladimir Kvashin & Vladimir Voskresensky, please review fix to integrate in 6.9.1
(In reply to comment #5) > Steps to reproduce bug: > - clear cnd cache > - start IDE > - d-n-d mysql-5.1.30/sql/mysqld into editor area > - create project > - wait finishing parsing > - delete project with sources > - exit IDE > Actual: IDE is not finishing for 3 minutes. > Expected: IDE is finishing for 3 seconds. This is somewhat different from my scenario. I don't close or delete any projects. The large project which I suspect is holding things up is open.
(In reply to comment #9) > This is somewhat different from my scenario. > I don't close or delete any projects. The large project which > I suspect is holding things up is open. Did you check fix on your use case? Root of problem is a slow method sun.nio.ch.FileChannelImpl.size0() on NFS. My fix removes a huge number of calls of sun.nio.ch.FileChannelImpl.size(). I believe that your use case has the same problem.
(In reply to comment #10) > Did you check fix on your use case? > Root of problem is a slow method sun.nio.ch.FileChannelImpl.size0() on NFS. > My fix removes a huge number of calls of sun.nio.ch.FileChannelImpl.size(). > I believe that your use case has the same problem. Ok, I'll give it a try. However, I'm stied tied to a 6.9 release and don't have a trunk handy. So it'll be a bit.
To check fix you can replace one module: - C/C++ Repository (org.netbeans.modules.cnd.repository.jar)
Integrated into 'main-golden', will be available in build *201006170001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/488bd1111b6d User: Alexander Simon <alexvsimon@netbeans.org> Log: fixed BZ#187219 sunstudio will not terminate when exiting IDE
fixed in release691: 488bd1111b6d transplanted to ad506829cbb8
Please mark bugs VERIFIED-FIXED before transplanting to release691. Please verify this bugfix asap. Thanks, -R
Please verify bugfix for this bug, so it can be integrated into release691 repository. Thanks, -R
I'll be able to verify it today. I've been doing disk housekeeping and cleaning on my machine so I can keep both a release69 and trunk NB repositories ...
IDE will now shutdown in reasonable time in the following scenarios: - shutdown after a "big project" has been parsed. - shutdown during a bug parse (initiated via ReparseProject action)
verified in 6.9.1. Ivan, please confirm.