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.
NB6, RC1, WinXPSP, JDK 1.6.0_02. I copied some Coldfusion (*.cf) files from elsewhere, browsed to the directory in the Favorites window, selected one of the files and tried to change the extension from .cfm to .jsp. After pressing Enter NB GUI completely hangs (still reacts to jconsole and jstack).
Created attachment 53186 [details] Threaddump from jstack
From threaddump it looks like deadlock between RequestProcessor thread and EventQueue thread, probably caused by cross locking locked <0x0d15c788> (a org.openide.windows.CloneableOpenSupport$Listener) I don't know where should we break such deadlock, but it seems strange that org.netbeans.modules.languages.features.LanguagesNavigator is trying to open some document as reaction to lookup change...
The issue is 100% reproducible (I tried to change the extension of another *.cfm file). Georg
It is related to the EncodingQuery, which caused many deadlocks early after implementation.
The lock up seems to occur every time I try to change the extension of a file to .jsp (tried this with a file in my local perl installation: evn.plex -> env.plex2 works, env.plex -> env.jsp locks up).
Just tried again with RC2 and still completely reproducible. I guess this is a showstopper, isn't it?
I don't know where should we break such deadlock too. Can some expert from core team look at it, please? My call (EditorCookie.openDocument () in Navigator) is not illegal, as far as I know. There is no restrictions on this method described in documentation. I can listen on EditorCookie.Observable, but I am not comfortable doing such changes after RC2. Can somebody form QA evaluate priprity of this issue (is it reproducible)?
Let's try DataSystems.
Ar first a cannot reproduce it but now I found it. Steps to reproduce: ------------------- 1) open a Nb Project (can reproduce at least with Web and J2SE) 2) create a 'New > Other ... > Other > Empty File' eg: abc 3) copy the file eg: into abc_1 4) rename abc_1 into abc.jsp ERROR: IDE locks But when you only create a new Empty file and then rename it to the abc.jsp things work well.
Well, this does not good. The Data system is somehow confused by a rename of some dataobject that triggers creation of new JSP object. That invalidates the previously existing object, which triggers Navigator, which triggers Schlieman, which then asks for a document using a blocking call. That call schedules another thread which gets into a starvation with the first thread doing the open. Indeed this is a bug in DataSystems, however I need about three days to fix it with 95% probability of doing correct fix. I need a day if I am lucky. My advice to Hanz was to use getDocument() instead of openDocument() which is non-blocking. Then we would trade this P1 for a P3 for Schlieman saying that: "Navigator is sometimes empty and user needs to choose switch to other component and back to get its content populated". Up to you to decide what to do.
Hanzi, please can you comment?
I can do that. So, questions for QA: is it show stopper? Should it be fixed in RC3? Are you comfortable with this solution (no deadlock, empty navigator on the first try)?
We agreed this is not a stopper for NetBeans 6, changing priority to P2. Jardo, it would be best if you could work on the patch for trunk - thanks.
After consultation with Jarda, I'm offering simple fix in navigator, see attached patch. Fix is just deletion of one if condition which ensures that Navigator will react on node destroy asynchronously - which is good and desired in fact, especially because navigator updates itself asynchronously in all other listener reactions cases, this was the only synchronous update trigger. Given that we have this simple and safe fix, i vote for including in 6.0. Please downgrade to P2 again if you disagree, thank you. Otherwise please Jarda review so that I can merge into release60 later, thanks. Checking in NavigatorController.java; /cvs/core/navigator/src/org/netbeans/modules/navigator/NavigatorController.java,v <-- NavigatorController.java new revision: 1.36; previous revision: 1.35
I have an independent fix of the problem in loaders as well: IDE:------------------------------------------------- IDE: [23.11.07 12:23] Committing "Datasystems API" started cvs server: scheduling file `DefaultDataObjectTest.java' for addition cvs server: use 'cvs commit' to add this file permanently RCS file: /shared/data/ccvs/repository/openide/loaders/test/unit/src/org/openide/loaders/DefaultDataObjectTest.java,v done Checking in test/unit/src/org/openide/loaders/DefaultDataObjectTest.java; /shared/data/ccvs/repository/openide/loaders/test/unit/src/org/openide/loaders/DefaultDataObjectTest.java,v <-- DefaultDataObjectTest.java initial revision: 1.1 done Checking in src/org/openide/text/DataEditorSupport.java; /shared/data/ccvs/repository/openide/loaders/src/org/openide/text/DataEditorSupport.java,v <-- DataEditorSupport.java new revision: 1.53; previous revision: 1.52 done IDE: [23.11.07 12:23] Committing "Datasystems API" finished
giorgio42, could you please verify the fix ? If so we can add it into next patch available on NB 6.0 UC. Thanks in advance.
Renaming works but there is another weird issue: I renamed a foobar.cfm file to foobar.jsp in the Favorites window. After that I changed to the Windows explorer and renamed it back to foobar.cfm, because I wanted to repeat the test. I noticed two problems: 1. Both files are visible in the Favorites window, although only one exists (usually the view in the Favorites window is updated automatically after some seconds), see screenshots. 2. When I select the foobar.cfm file and then the non-existing foobar.jsp it takes several seconds until the selection highlight moves to the foobar.jsp file.
Created attachment 55795 [details] Screenshot of Favorites window
Created attachment 55796 [details] Screenshot of the Favorites window (correct MIME type)
Created attachment 55797 [details] Actual contents of file system (explorer screen shot)
giorgio42, you verified the issue in development build, right? It seems that the issue was caused by the FS change (issue 123542). What build did you use for testing? It doesn't happen in my config - Product Version: NetBeans IDE Dev (Build 200801300005), Java: 1.6.0_04; Java HotSpot(TM) Client VM 10.0-b19, System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb) thank you for verification
I used either 6.1M1 or 6.1 200801271318 (can't remember exactly) and: java version "1.6.0_10-ea" Java(TM) SE Runtime Environment (build 1.6.0_10-ea-b10) Java HotSpot(TM) Client VM (build 11.0-b09, mixed mode, sharing)
The fix has been ported into the release601_fixes branch. cvs add DefaultDataObjectTest.java cvs server: scheduling file `DefaultDataObjectTest.java' for addition on branch `release601_fixes' cvs server: use 'cvs commit' to add this file permanently Checking in src/org/openide/text/DataEditorSupport.java; /cvs/openide/loaders/src/org/openide/text/Attic/DataEditorSupport.java,v <-- DataEditorSupport.java new revision: 1.52.8.1; previous revision: 1.52 done Checking in test/unit/src/org/openide/loaders/DefaultDataObjectTest.java; /cvs/openide/loaders/test/unit/src/org/openide/loaders/Attic/DefaultDataObjectTest.java,v <-- DefaultDataObjectTest.java new revision: 1.2.2.1; previous revision: 1.2 done Checking in src/org/netbeans/modules/navigator/NavigatorController.java; /cvs/core/navigator/src/org/netbeans/modules/navigator/Attic/NavigatorController.java,v <-- NavigatorController.java new revision: 1.33.2.1.4.1; previous revision: 1.33.2.1 done
The module org-openide-loaders.nbm requests org-openide-modules-os-MacOSX.nbm during installation into the IDE. I'm removing the release601_fixes_fixed status whiteboard.
Removing release601_fixes_candidate1 status whiteboard value. The fix cannot be ported to the fixes branch, since it cannot be made available on the update center: see http://www.netbeans.org/issues/show_bug.cgi?id=127593 . Rolled back the changes to release601_fixes branch: Checking in src/org/openide/text/DataEditorSupport.java; /cvs/openide/loaders/src/org/openide/text/Attic/DataEditorSupport.java,v <-- DataEditorSupport.java new revision: 1.52.8.2; previous revision: 1.52.8.1 done Removing test/unit/src/org/openide/loaders/DefaultDataObjectTest.java; /cvs/openide/loaders/test/unit/src/org/openide/loaders/Attic/DefaultDataObjectTest.java,v <-- DefaultDataObjectTest.java new revision: delete; previous revision: 1.2.2.1 done Checking in src/org/netbeans/modules/navigator/NavigatorController.java; /cvs/core/navigator/src/org/netbeans/modules/navigator/Attic/NavigatorController.java,v <-- NavigatorController.java new revision: 1.33.2.1.4.2; previous revision: 1.33.2.1.4.1 done