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 115358 - Horrible performance of delete action
Summary: Horrible performance of delete action
Status: RESOLVED WONTFIX
Alias: None
Product: platform
Classification: Unclassified
Component: Data Systems (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Jaroslav Tulach
URL:
Keywords: PERFORMANCE
: 119351 (view as bug list)
Depends on: 117422 117355
Blocks:
  Show dependency tree
 
Reported: 2007-09-12 15:11 UTC by Jan Becicka
Modified: 2008-12-22 10:48 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Full thread dump (53.83 KB, text/plain)
2007-09-12 15:19 UTC, Jan Becicka
Details
Snaphost of delete of my NetBeans 5.5.1 installation (1.18 MB, application/octet-stream)
2007-09-27 10:18 UTC, Jaroslav Tulach
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Becicka 2007-09-12 15:11:05 UTC
I need to do some cleanup in java module. I selected several modules in Favorites Tab (javacore, src, srcmodel, parser)
and tried to delete. After a while IDE hanged, because it was completely overloaded.
I need to kill the IDE and do deletion by hand.
Comment 1 Jan Becicka 2007-09-12 15:19:51 UTC
Created attachment 48659 [details]
Full thread dump
Comment 2 mslama 2007-09-12 18:02:27 UTC
Favorites just calls delete on underlying DataObject as you can see in AWT thread. Passing to loaders for evaluation.
Comment 3 mslama 2007-09-12 18:07:55 UTC
Favorites could run this as background task and not to block AWT thread. But this would not fix primary problem: Why
there is so many XmlFoldManager threads and why call stack of Module-Actions thread is so deep adn why it is waiting on
lock which is not held elsewhere.
Comment 4 Jan Becicka 2007-09-13 06:17:57 UTC
I think, that deep Module-Action thread is OK. It is probably recursive delete of deep directory tree.
Comment 5 Petr Nejedly 2007-09-19 14:24:26 UTC
I have filed issue 116004 about the TimerTasks.
Still, it is suspicious that they were created at all.
Did you have opened any xml files (or more specifically tens of them)? In a "show changes" dialog? Or as diffs?

The problem with slow deletion is heavily influenced by the fact tha the IDE first recognizes all the files and then
deletes them as they wish - i.e. the deletion is performed on the DataObject level with all the whistles.
Comment 6 Jaroslav Tulach 2007-09-27 10:17:28 UTC
After looking at profiling output, I suspect the biggest hotspot is localhistory.
Comment 7 Jaroslav Tulach 2007-09-27 10:18:41 UTC
Created attachment 49658 [details]
Snaphost of delete of my NetBeans 5.5.1 installation
Comment 8 Jan Becicka 2007-10-01 07:34:03 UTC
> Did you have opened any xml files (or more specifically tens of them)? In a "show changes" dialog? Or as diffs?

I probably had some xml files open, possibly some diffs, but definitely not those, I wanted to delete.
Comment 9 Jan Becicka 2007-10-01 17:02:16 UTC
I cannot reproduce the hang, but performance is still horrible. Now I tried to delete ruby project. I lost my patience
after 45 minutes.
Thread dump shows activity in 
org.netbeans.spi.java.project.support.ui.PackageView.findNonExcludedPackages(PackageView.java:162)
and in org.netbeans.modules.localhistory.utils.FileUtils.copy(FileUtils.java:92)

It looks like implementation of delete action is simply not designed for such operations. I'm not able to expand folders
in favorites tab (it is immediately collapsed back) and I see flashing progress "finding packages in ...".
CPU is at 100%.




Comment 10 Tomas Stupka 2007-10-01 18:01:53 UTC
the localhistory is copying files into its storage before they get deleted. This takes some time, whether zipping them
or not. I've filed a new bug to deal with it (117355), still - there seems to be more in this issue ...

- the originally reported hung up - could not reproduce and i also haven't seen anything related to the LH in the
attached thread dump. 

- flashing favorites tab - reassigning for further evaluation.

Comment 11 mslama 2007-10-02 11:31:49 UTC
Ok separate issue for localhistory is filled and marked as blocker for this issue. For unneeded refresh of TreeView I
file separate issue against openide/explorer #117422. Not sure if there is anything else besides localhistory issue. If
not you can close this issue. 

Note:
tstupka if you change component/subcomponent you should also change owner. As I handle more components I check only
issues assigned directly to me. I do not have query with list of ~ 5 IZ components and check all issues in these
categories again and again..... Result is that such issue with incorrect owner can lay in IZ looong time without
notice......
Comment 12 Jaroslav Tulach 2007-10-03 15:44:07 UTC
Two issues are filed, I do not think there is anything to do here anymore.
Comment 13 mslama 2007-10-18 16:42:18 UTC
*** Issue 119351 has been marked as a duplicate of this issue. ***
Comment 14 mslama 2007-10-18 16:42:52 UTC
*** Issue 119351 has been marked as a duplicate of this issue. ***