0

I've tried so much I'm almost breaking my laptop on my forehead. But it was an expensive piece of equipment and I need it for my job, so I will try StackOverflow first.

I've got this huge Node.JS project in Eclipse. Eclipse has always been sluggish, but now it's gotten to the point where after every few keystrokes, Eclipse will freeze for minutes with the processor at 100%, often ending with some random useless error message like garbage collection ran out of memory or whatever.

Whatever it is, I don't need it to happen after every few keystrokes! Sometimes, this error message appears, with the advise to disable Template Proposals. I've had the same dialog advising me to disable pretty much everything else that is useful, to the point that Eclipse is starting to become quite similar to your next enhanced Notepad application.

enter image description here

  • Is it really so impossible to have IDE-trickery such as code assist and completion (AKA the whole reason to use an IDE in the first place) with Eclipse, even working with projects bigger than two lines of code?
  • Why would Ctrl+Space take a minute of 100% CPU when the only assist I have enabled is a handful of templates and the others are disabled? enter image description here

Please share the secret option with me that makes Eclipse usable.


$ cat /etc/eclipse.ini | grep Xm
-Xms40m
-Xmx384m
 $ cat /opt/eclipse/eclipse.ini | grep Xm
-Xms40m
-Xmx512m
$ cat /usr/lib/eclipse/eclipse.ini | grep Xm
-Xms40m
-Xmx384m
4

1 回答 1

1
  1. Preferences--> Editors--> Content Assist: 禁用自动激活。您仍然可以将它与Ctrl + <Space>.

  2. 禁用工作区的保存时构建。

  3. 万不得已禁用Preferences-->Validation

  4. -Xms您可以通过在启动时提供和参数来增加 eclipse 的可用内存-Xmx,例如:eclipse -vmargs -Xms256M -Xmx1024M。更多信息在eclipse wiki

于 2014-03-19T08:53:53.287 回答