为GAE设置JRebel

时间:2013-09-26 19:41:45

标签: java google-app-engine maven jrebel

我需要尝试使用JRebel进行网络应用开发:

  • 使用GAE SDK版本1.8.0
  • 浏览maven appengine:devserver
  • 在M2E插件(Eclipse)或控制台下运行Linux(Ubuntu)桌面

我在网上找到的文件指向编辑GAE脚本,但是从Maven运行GAE的方法是什么?

1 个答案:

答案 0 :(得分:7)

这里的问题是使用JRebel JVM参数启动GAE流程,或者通常将JVM参数添加到GAE流程。

有多种方法可以向进程添加JVM参数,我建议将这些参数添加到appengine插件

您可以在pom.xml中为JRebel设置JVM参数:

<plugin>
  <groupId>com.google.appengine</groupId>
  <artifactId>appengine-maven-plugin</artifactId>
  <version>${appengine.target.version}</version>
  <configuration>
    <jvmFlags>
      <jvmFlag>-agentpath:{jrebel install directory}/lib/libjrebel64.dylib</jvmFlag>
    </jvmFlags>
    <disableUpdateCheck>true</disableUpdateCheck>
  </configuration>
</plugin>

libjrebel64.dylib适用于macOS,您在Linux上使用libjrebel64.so,在Windows上使用jrebel64.dll