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 248900 - Git diff is ridiculously slow
Summary: Git diff is ridiculously slow
Status: RESOLVED FIXED
Alias: None
Product: utilities
Classification: Unclassified
Component: Diff (show other bugs)
Version: 8.1
Hardware: All All
: P3 normal (vote)
Assignee: Ondrej Vrabec
URL:
Keywords: PERFORMANCE
Depends on:
Blocks: 253748
  Show dependency tree
 
Reported: 2014-11-25 19:55 UTC by Jesse Glick
Modified: 2015-07-25 18:13 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 213693


Attachments
nps snapshot (137.01 KB, application/nps)
2014-11-25 19:55 UTC, Jesse Glick
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jesse Glick 2014-11-25 19:55:21 UTC
This issue was reported manually by jglick.
It already has 2 duplicates 


Build: NetBeans IDE Dev (Build 20141110-6ca365d62b59)
VM: Java HotSpot(TM) 64-Bit Server VM, 24.65-b04, Java(TM) SE Runtime Environment, 1.7.0_67-b01
OS: Linux

User Comments:
jglick: Trying to diff a pom.xml to which I had made a one-line change. Why does this take so long? git diff HEAD is instantaneous.

jglick: Running a diff.



Maximum slowness yet reported was 16069 ms, average is 13706
Comment 1 Jesse Glick 2014-11-25 19:55:23 UTC
Created attachment 150703 [details]
nps snapshot
Comment 2 Tomas Stupka 2015-03-18 14:01:45 UTC
maven project loading was triggered by diff 
DataEditorSupport.getSourceDocument() -> FileEncodingQuery.getEncoding() -> FOQ.getOwner() -> ...
and resolving the projects dependencies eat up most of the necessary time

similar scenario with other snapshots
Comment 3 Tomas Stupka 2015-06-17 09:38:54 UTC
EditableDiffView.getSourceDocument() -> FEQ -> FOQ -> NbMavenProjectFactory.loadProject() 
not much we can do about it in maven - loading a project takes time

please evaluate if this has to be called in AWT
Comment 4 Ondrej Vrabec 2015-07-08 15:23:04 UTC
Fix: core-main #43d47b394a48
Changeset: 43d47b394a48
Message:   Reschedule opening file to a background thread.
Comment 5 Quality Engineering 2015-07-17 01:19:13 UTC
Integrated into 'main-silver', will be available in build *201507170001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/43d47b394a48
User: Ondrej Vrabec <ovrabec@netbeans.org>
Log: #248900 - Git diff is ridiculously slow
Reschedule opening file to a background thread.