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 179124 - IDE is frozen and not redrawn when for "Open Project..."
Summary: IDE is frozen and not redrawn when for "Open Project..."
Status: RESOLVED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Directory Chooser (show other bugs)
Version: 6.x
Hardware: PC Solaris
: P2 normal (vote)
Assignee: David Simonek
URL:
Keywords:
: 110904 (view as bug list)
Depends on: 182605
Blocks:
  Show dependency tree
 
Reported: 2009-12-30 05:46 UTC by Vladimir Voskresensky
Modified: 2010-03-23 22:46 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
thread dump (19.41 KB, text/plain)
2009-12-30 05:48 UTC, Vladimir Voskresensky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Voskresensky 2009-12-30 05:46:40 UTC
In the recent trunk build () Open Project is extremely slow (about 10 sec) before displaying dialog.
Comment 1 Vladimir Voskresensky 2009-12-30 05:48:11 UTC
Created attachment 93008 [details]
thread dump

thread dump during frozen IDE 
Product Version: NetBeans IDE Dev (Build 091230-b1ad2996ff17)
Java: 1.6.0_14; Java HotSpot(TM) Client VM 14.0-b16
System: SunOS version 5.10 running on x86; UTF-8; en_US (nb)
Comment 2 David Simonek 2010-01-04 03:00:42 UTC
It seems to be duplicate of 110904. I wasn't able to reproduce on my Ubuntu Linux. Are there any special steps or maybe Solaris specific?
Comment 3 Vladimir Voskresensky 2010-01-04 14:11:29 UTC
It may be NFS-based filesystems specific. Home is on NFS folder and home is the default start folder?
Comment 4 David Simonek 2010-02-01 09:00:50 UTC
Yes NFS could be the reason - Vladimir could you check if the problem applies to local FS as well? I think just opening something from local FS and invoking Open project again will show it, as dialog remembers last location. Thank you.
Comment 5 David Simonek 2010-02-09 09:23:16 UTC
Or maybe please give me instructions (offline) how to mount NFS where you are experiencing problems. I tried to find some sample public NFS server on inet, but failed, probably because of security issues.
Comment 6 Vladimir Voskresensky 2010-02-09 10:02:43 UTC
Hi David,
I do not have such issue now, but you can easily emulate it.
Just put on line 1115 of file DirectoryChooserUI.java
                    try {
                        Thread.sleep(10000);
                    } catch (InterruptedException ex) {
                        Exceptions.printStackTrace(ex);
                    }
that can help you to simulate long NFS for
                    node = new DirectoryNode(file);
                    node.loadChildren(fileChooser, true);
and you will see frozen UI
I've tried and it is 100% reproducible :-)
Comment 7 David Simonek 2010-02-12 06:33:31 UTC
Yep, thanks for the hint, I thought about it too but was too lazy :-)
Comment 8 Antonin Nebuzelsky 2010-03-01 03:04:27 UTC
> I do not have such issue now, but you can easily emulate it.

Is this a real issue then?
Comment 9 Vladimir Voskresensky 2010-03-01 04:21:08 UTC
(In reply to comment #8)
> > I do not have such issue now, but you can easily emulate it.
> 
> Is this a real issue then?

as soon as file system has *any* slowness (i.e. NFS is slow) => yes.
Btw, from implementation point of view DirectoryChooserUI.java has an error.
There is no reason to do in EDT the following:
 methodCalledFromEDT() {
  task = RP.post(Runnable {
            long operation here...
         });
  task.wait();
 }
because from  it's the same as 
 methodCalledFromEDT() {
Comment 10 Vladimir Voskresensky 2010-03-01 04:21:58 UTC
sorry, interrupted :-)
impl is incorrect, because long operation still locks EDT
Comment 11 David Simonek 2010-03-01 08:01:59 UTC
Yes, agreed with Vladimir. We had various reports of slowness in the past, probably coming from slower FS.
Comment 12 David Simonek 2010-03-22 17:00:30 UTC
fixed, updateTree calls optimized and queue for handling update requests introduced:
4515790622ab
Comment 13 Quality Engineering 2010-03-23 05:10:05 UTC
Integrated into 'main-golden', will be available in build *201003230200* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/4515790622ab
User: Dafe Simonek <dsimonek@netbeans.org>
Log: #179124: updateTree call frequency lowered, introduced blocking queue run in RequestProcessor to be able to handle multiple update requests outside of event dispatch thread
Comment 14 David Simonek 2010-03-23 16:25:54 UTC
*** Bug 110904 has been marked as a duplicate of this bug. ***