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.
080121. Running Diff on the NB repo blocks EQ, and for quite a long time at that. Any Hg operation should be run asynchronously. I suggest that HgCommand.exec be fixed to throw an assertion error if invoked on EQ, since it is never permissible to do so.
Created attachment 55517 [details] Dump of EQ thread
Is there a helper method we can use to detect if we are being called from within the main EQ?
EventQueue.isEventDispatchThread() Well I found one reason it is so excruciatingly slow compared to 'hg diff': $ ps www `pgrep hg` PID TTY STAT TIME COMMAND 10311 ? R 0:02 /usr/bin/python /home/jglick/bin/hg log -l 1 --repository /space/hgsrc/main --template={rev}:{node|short}\n /space/hgsrc/main/nbbuild/netbeans/nb.cluster.ide.built I have no idea what the purpose of this call is, but if you just run 'hg diff' it will tell you what modifications were made, including file additions and deletions, using one command.
In MercurialAnnotator.formatAnnotation() if you have turned on VersionControl labels and are including {revision} you will be making a call to get the last revision for each displayed file in the Project view. The call to getLatRevision() results in the: hg log -l 1 --repository <repo> --template="{rev}:{node|short}\n" <filename> This is a serious performance hit. Its logged as bug #124895 "Revision number in Status labels and performance" and we are looking into caching the information when the file is placed in the cache initially.
I don't think I've "turned on VersionControl labels" (at least "Mercurial Status Labels" in Options is blank), and I do not see any extra information in the Projects tab except (1) color on individual files, (2) a somewhat cryptic label " [main]" following the project name. Anyway I'm not sure what display of file nodes in the Projects tab has to do with the performance of a Diff operation.
Jessie - can you add to your etc/netbeans.conf: netbeans_default_options="... -J-Dorg.netbeans.modules.mercurial.level=100 ..." to your run your diff command again and send us the var/log/messages.log file Thanks.
Using the XXX version of the mercurial module, I can again reproduce the problem. I just opened nbbuild, made an edit to one file in it, then selected the project and invoked Diff. IDE froze with 100% CPU. (Well, actually 50% - I have dual core.) Same EQ activity as before. Amusingly, when I ran ps www `pgrep hg`, I found /usr/bin/python /home/jglick/bin/hg log -l 1 --repository /space/src/nb/main --template={rev}:{node|short}\n /space/src/nb/main/nbbuild/netbeans/nb.cluster.ruby.built which is amusing since this file does not actually exist: $ ls nbbuild/netbeans/ extra ide8 moduleCluster.properties nb.cluster.platform.built platform7 I'm tempted to make P1 since if you are unlucky enough to try to run Diff from the IDE you will probably need to killall java.
Created attachment 55686 [details] Log file lines mentioning mercurial
I meant to say: "Using the 030d8a2ae77b version of the mercurial module..."
We are attempting to display the changesetID in the Diff window. I note that in the Subversion Diff window there is no reference to the version of the file. I propose to not display the changesetID in the mercurial Diff window.
Created attachment 55736 [details] proposed patch
bash-3.2$ hg out -v comparing with http://hg.netbeans.org/main searching for changes changeset: 65116:a6fb30bb7ab5 tag: tip user: padraigob@netbeans.org date: Wed Jan 30 08:59:11 2008 +0000 files: mercurial/src/org/netbeans/modules/mercurial/ui/diff/Setup.java description: Issue 125939: Do not get changeset ID for Diff.
*** Issue 126143 has been marked as a duplicate of this issue. ***
You must set a target milestone when closing any issue as FIXED. Changeset ID should suffice for comment.