I was reading this blog post about the experience of a team using Intellij Idea for large maven projects and have also looked at a similar question posted around 2 years back for IDEA v.10.0.2.
One of the tips mentioned in the former made a whole lot of sense :
Move C:\Users\$user\.IntelliJIdea12
into a folder not access-scanned by the antivirus.
I have searched around for performance centric VM options and currently my idea64.exe.vmoptions
looks like this :
-Xms1200m
-Xmx1200m
-XX:MaxPermSize=200m
-ea
-server
-XX:+DoEscapeAnalysis
-XX:+UseCompressedOops
-XX:+UnlockExperimentalVMOptions
-XX:+UseParallelGC
-XX:ReservedCodeCacheSize=64m
-XX:+UseCodeCacheFlushing
-Dsun.io.useCanonCaches=false
Questions
Do you have any more such tips to improve Intellij IDEA (12.1.3, 64 bit) performance with large/huge maven projects ?
Could you please share discoveries you have made w.r.t VM options in
idea64.exe.vmoptions
and/or IDEA configuration inidea.properties
.I have tried using JDK 7 to startup IDEA but this does not seem to terribly affect it's performance one way or the other. If you have tried doing so, did you experience the same ?
IntelliJ IDEA 2017.2 Added really nice feature, which helps a lot when working with large projects. Basically, you can mark which modules will be loaded by IDEA and which not. Unloaded modules will not be touched in any way by the IDE. They will not be indexed, searched, they will not be subject to refactoring on inspections. Loaded/Unloaded modules can be quickly configured in Load/Unload Modules dialog. The dialog can be opened using
Temporarily reducing the number of modules IDEA works with will greatly increase the performance for big projects. You can find more info about this feature and other performance tweaks for IntelliJ IDEA in a blog post I wrote: IntelliJ IDEA Tips & Tricks: Improving performance
Sometimes you can run out of memory on a large project. An import process of the large maven project fails then.
So if any of modules of your project is underlined with a red line and you see
on it, go to "Settings -> Build Tools -> Maven -> Importing", and find the "VM options for importer" option there. Increase the limit, set it to
-Xmx1g
(or more).(Source)
As suggested by @CrazyCoder, I followed the steps on the official FAQ regarding this matter:
Common solutions for IntellJ IDEA performance problems
Specifically, the following seemed to have had an appreciable affect:
Moved the
c:/Users/$user/.IntelliJIdea12
to a location excluded by McAfee's on-access-scanner, and updated$INTELLJ_INSTALL_FOLDER/bin/idea.properties
to point to the new location like so (wherec:/dev
is the folder excluded by McAfee):In
$INTELLJ_INSTALL_FOLDER/bin/idea.properties
setidea.jars.nocopy=true
as documented in this blog post.Reverted back to the stock
$INTELLIJ_INSTALL_FOLDER/bin/idea64.exe.vmoptions
. The only changes that remains are those suggested in Too low heap size for a 64-bit JVM. Here is what I have in the that file currently:Disabled Git integration plugin since I mostly use command line Cygwin-Git.
It was useful to monitor
.IntelliJIdea12/idea.log
. For example : I disabled the osmorc (for OSGI) plugin after seeing that it was frequently logging error while trying to opening zip files in the projects. Sample error :Disabled all the plugins that I do not need. The current list of disabled plugins is :