JRebel4.0 在Eclipse中配置使用说明

来源:互联网 发布:视频剪辑edius软件价格 编辑:程序博客网 时间:2024/06/05 03:32

1. 双击Eclipse中的Server在打开的配置画面的Overview Tab页中点击【open launch configuration】,然后在弹出画面的【VM arguments】中加入

JVM参数

-javaagent: D:\java\driver\JRebel4.0.1\jrebel.jar   -- 你存放jrebel.jar的位置 (任意)

-Dmyproject.root=D:/java/project/xxx  -- 你项目工程位置

-noverify

-Drebel.spring_plugin=true 

-Drebel.ibatis_plugin=true  -- 改Ibatis配置文件将不用重启服务器,JRebel 会自动 Reloading sql maps.

-Drebel.log=false

-Drebel.disable_update=true
-Drebel.camel_plugin=true
-Drebel.click_plugin=true
-Drebel.jruby_plugin=true
-Drebel.jersey_plugin=true
-Drebel.adf_core_plugin=true
-Drebel.adf_faces_plugin=true
-Drebel.restlet_plugin=true
-Drebel.seam_wicket_plugin=true
-Drebel.spring_data_plugin=true
-Drebel.webobjects_plugin=true

-Drebel.workspace.path=D:\java\project

-Drebel.metadata.path=D:\java\project\.metadata\.jrebel

使用目录下的jrebel.jar 蓝色的为可选参数,可以不加


使用目录下的jrebel4.jar(注意,改名成jrebel.jar后再使用)

1. 必须把rebel.xml放到项目的SRC目录

2. 必须把Eclipse Server配置页面中的发布选项改为【不自动发布】

3. Eclipse->Project->Build Automatically 必须勾上

4. myproject.root指定到Eclipse中相应项目的目录,该变量被rebel.xml使用(JRebel4.0通过监控rebel.xml中指定的目录来自动重载变更过的java,jsp文件)

jrebel3.1才开始支持ibatis

3.6才支持使用spring template的ibaits
具体-D后面的参数名称,可以参考jar包中相应plugin包中的相应插件类:如IbatisPlugin
getId()方法返回的就是设置的参数


附.rebel.xml

[html] view plaincopyprint?
  1. <?xmlversion="1.0"encoding="UTF-8"?> 
  2. <applicationxmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xmlns="http://www.zeroturnaround.com"xsi:schemaLocation="http://www.zeroturnaround.com http://www.zeroturnaround.com/alderaan/rebel-2_0.xsd"> 
  3.  
  4.     <classpath> 
  5.         <dirname="${myproject.root}/build/classes"> 
  6.         </dir> 
  7.     </classpath> 
  8.  
  9.     <web> 
  10.         <linktarget="/"> 
  11.             <dirname="${myproject.root}/WebContent"> 
  12.             </dir> 
  13.         </link> 
  14.     </web> 
  15.  
  16. </application> 

改Tomcat的配置文件server.xml中的

<Context docBase="xxx" path="/xxx" reloadable="false" source="org.eclipse.jst.jee.server:mmt"/></Host>

另: tomcat溢出解决办法

双击Eclipse中的Server在打开的配置画面的Overview Tab页中点击【open launch configuration】,然后在弹出画面的【VM arguments】中加入

-Xms256m
-Xmx256m
-XX:MaxNewSize=256m
-XX:MaxPermSize=256m

修改Timeouts的参数  Start :120  Stop :15

原创粉丝点击