Tuesday, December 13, 2011

Eclipse preferences

  1. Hot deploy on Tomcat - when you make changes to class it should be asap visible in Tomcat (JRebel would like that :)
    • Create Launch Configuration under Tomcat - Launch (Preferences), Debug is checked
    • This is working only on web project, not projects included in it
  2. General - check Show heap status
  3. General - Workspace - set Text file encoding
  4. General - Editors- Text Editors - Show line nubers
  5. Run/Debug - Console - uncheck Limit console output
  6. modify start shortcut: 
    • "C:\MyEclipse\myeclipseforspring.exe" -data D:\Workspace\Play -vmargs -Xmx768m -XX:MaxPermSize=384m -XX:ReservedCodeCacheSize=64m
  7. add latest Subclipse
  8. add bin and target folders to global svn ignore list
    • Windows - Preferences - Team - Ignored Resources - Add Pattern
    • enter bin then target then m2-target
  9. remove antivirus scan from workspace and eclipse installation directory
  10. add -showlocation as first line in eclipse.ini to show workspace location in title bar
Find resource in specific folder?
Open resource (Ctrl + Shift + R) - find start.jsp in msgbox subfolder:
*/msgbox/start.jsp

How to tell eclipse where is my java located?
Edit eclipse.ini file add line before -vmargs:
-vm (new line needed :)
C:\Java\jdk1.6.0\jre\bin\javaw.exe

How to change @author default field in Javadoc?
Edit eclipse.ini file, add line
-Duser.name=My name

Missing deployment assembly even if Dynamic Web Module is added as project facet
Add
 <nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
to your .project file.

Quick Search
CTRL+SHIFT+L
https://marketplace.eclipse.org/content/quick-search-eclipse
https://spring.io/blog/2013/07/11/eclipse-quick-search/

Add decompiler
http://jadclipse.sourceforge.net/wiki/index.php/Main_Page
http://www.mkyong.com/java/java-decompiler-plugin-for-eclipse/

Ref:
http://wiki.eclipse.org/Eclipse.ini
What are the best JVM settings for Eclipse?
https://dzone.com/articles/show-workspace-location-title


TOMCAT - JVM parameters:
-Xms256m -Xmx1024m 
-XX:PermSize=64m -XX:MaxPermSize=512m
-Dorg.apache.el.parser.COERCE_TO_ZERO=false
-Dsun.jnu.encoding=UTF-8 
-Dfile.encoding=UTF-8


JVM params explained

-Xms<size>              set initial Java heap size
-Xmx<size>              set maximum Java heap size
-XX:PermSize<size>  set initial PermGen Size
-XX:MaxPermSize<size>  set the maximum PermGen Size
https://www.mkyong.com/java/find-out-your-java-heap-memory-size/

No comments:

Post a Comment