使用JavaRebel實現Eclipse即時重載javaclass更改

第一步: 下載JavaRebel包  java

咱們須要去下載JavaRebel的包, 我這裏暫時不提供下載地址,由於我本身有軟件潔癖,必定要官方的, 以前我是別人給個人, 仍是但願你們去官方網站下載好. web

第二步: 配置Eclipse的Overview spring

若是你這個頁面不知道在哪兒的話, 請雙擊大家server下的Tomcat. 就會知道了. tomcat

將下載好的JavaRebel包,直接解壓就好.進入Overview頁面.如圖所示: app


第三步: 配置jrebel相關參數,如圖所示


其中, 包含以前解壓的包的位置, 還有struts, Spring相關的開關. 都寫爲true就能夠了. 網站


 說明:

  -Drebel.dirs 指定要監控的 編譯後的java 文件目錄,這個目錄和上邊javarebel.jar的路徑千萬不要有空格和中文,最好連.也不要有。

  -Drebel.spring_plugin 表示對Spring的支持,默認是false

  -Drebel.struts2-plugin=true,這裏是-而不是_,千萬不要自做聰明喲。


第四步:配置Modules,將auto reload 變成disabled spa


簡單的配置就差很少完成了,啓動tomcat,出現:

#############################################################

 JRebel 4.0 (201105311152)
   with Enterprise Add-On! (see http://jrebel.com/enterprise)
 (c) Copyright ZeroTurnaround OU, Estonia, Tartu.

 Over the last 1 days JRebel prevented
 at least 1 redeploys/restarts saving you about 0 hours.

 This product is licensed to www.imxylz.info
 for unlimited number of developer seats on site.
 cracked by imxylz (imxylz@gmail.com) from JavaRebel 2.0-M1, 2008

 The following plugins are disabled at the moment:
 * Apache Click plugin (set -Drebel.click_plugin=true to enable)
Reloads menu.xml menu definitions of Apache Click projects.
 * Glassfish METRO plugin (set -Drebel.metro_plugin=true to enable)
Supports METRO JAX-WS 2.2.3 implementation of the JAX-WS standard
 * JBoss AOP Plugin (set -Drebel.jbossaop_plugin=true to enable)
Integration with jboss aop agent
 * Jackson Plugin (set -Drebel.jackson_plugin=true to enable)
Supports reloading Jackson's JsonSerializer caches.
 * Lift Plugin (set -Drebel.lift_plugin=true to enable)
Supports reloading singleton objects that extend RestHelper, MVCHelper,
LiftScreen or Wizard.
 * RESTEasy Plugin (set -Drebel.resteasy_plugin=true to enable)
Supports adding/changing methods with @Path annotation for RESTEasy application.
 * Seam Wicket Plugin (set -Drebel.seam_wicket_plugin=true to enable)
Integration with load time weaving seam annotations to wicket classes
(-javaagent:<path-to-jboss-seam-wicket-jar>)
 * WebObjects Plugin (set -Drebel.webobjects_plugin=true to enable)
WebObjects JRebel Plugin

#############################################################


JRebel: A newer version '5.2.0' is available for download
JRebel: from http://www.zeroturnaround.com/jrebel/upgrade/

JRebel: Directory 'D:\server\wenda\trunk\WebContent\WEB-INF\classes' will be monitored for class changes.
說明配置成功了!
相關文章
相關標籤/搜索