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.
Created attachment 135568 [details] thread dump NetBeans IDE Dev 201306082301
*** Bug 230596 has been marked as a duplicate of this bug. ***
The AWT thread notifies document close while one of the listeners org.netbeans.modules.css.model.api.Model.propertyChange(Model.java:228) forces openDocument() synchronously which starts "org.openide.text Document Processing" thread which loads the document and begins to fire listeners about document was loaded. It's a question whether we should allow to reopen document synchronously during notification about its closing.
Priority set to P2 since this is currently not a beta stopper.
I'm able to simulate the problem with a CloneableEditorSupportTest. Depending on machine speed it ends up repetitively opening and closing the document (due to CES$StrongRef being GCed and calling CES.closeDocument()). This makes the machine busy and it possibly leads to OOME being thrown followed by a state when there's typically a single thread waiting in CES.openDocumentImpl() on CES.getLock() but there is no thread that would awaken it.
*** Bug 231515 has been marked as a duplicate of this bug. ***
Fix of issue #228991 does CES.closeDocument() in RP thread and allows for synchronous CES.openDocument() from the close notification (there's a CloneableEditorSuppoortOpenCloseTest added for it) so this issue should be resolved. *** This bug has been marked as a duplicate of bug 228991 ***