17 private links
About a month ago, I blogged about my love/hate relationship with Eclipse. I was asked by a few people to share my tips on how I was able to speed it up so here we go… As a side note, this article is not about comparing IDEs, please refrain from displaying your hate for the IDE or your preference for another… This post is just about optimizations that help Eclipse run faster for those who use it. I’ve described each tip for Windows, Linux and MacOS users. Once you have gone through all the optimization tips, Eclipse should start within 10 seconds and run much smoother than before.
[edit]: most of those tips will speed up your Eclipse experience, not just the startup time. Classes will open faster, jumping from one definition to another will be faster. Viewing method javadocs will be faster… Unfortunately, none of that can be timed precisely so there is no specific benchmark about the actual speed gains for each tip.
When compared to NetBeans, I find that Eclipse is a lot slower, particularly when doing enterprise development. To try and speed Eclipse up, I’ve taken the JVM settings that NetBeans uses and applied them to Eclipse. The result is a vast improvement in performance. The default JVM settings in Eclipse aren’t optimal.
JVM GC tuning is a vast field that books have been written about. Mostly, we’re happy to accept whatever defaults the JVM figures out, at most cranking up heap and permGen size when we’re out of memory (again).
Besides the fact that a glorified Texteditor with a compiler attached needs gigabytes of memory, the darned thing was still slow, often becoming unresponsive for some seconds. This sucks.
Eclipse Che is a developer workspace server and cloud IDE.
Disable GTK+ 3
When the SWT GTK+ 3 UI is buggy and sometimes unusable, You can try to disable the use of GTK+ 3 with the SWT_GTK3=0
environment variable when you start eclipse:
SWT_GTK3=0 eclipse
Another option to achieve the same effect is to add the follwoing to /usr/lib/eclipse/eclipse.ini
.
--launcher.GTK_version
2
Those two lines must be added before:
--launcher.appendVmargs
Also note that if you do this, the Javadoc pop ups do not get rendered properly anymore if the package webkitgtk2 is not installed.
Annoyed by the fact you have to F5 (refresh) the workspace each time you change a Git branch or when you add images created from another software?
There is a native parameter in the "Worspace" section of the Eclipse preferences that could help.
It's called "Refresh using native hooks or polling". Auto-informing isn't it?
https://marketplace.eclipse.org/content/autorefresher#comment-3703