【问题标题】:Jrebel Synchronize With Apache TomcatJrebel 与 Apache Tomcat 同步
【发布时间】:2014-11-11 10:16:02
【问题描述】:

您好,这是成功完成 JRebel 设置后的 Eclipse 控制台日志。在 Java 文件中进行了更改并单击了同步。

 Response headers: [Server: Apache-Coyote/1.1, x-rebel-response: ERR_UNKNOWN_REBEL_HASH, x-rebel-responseMessage: Remoting module '5e1de368dea571c9bc1939d90988e22a746772ce' was not found, Content-Length: 0, Date: Wed, 12 Nov 2014 09:56:42 GMT]
[2014-11-12 02:56:42] Cannot find such project on the remote server. Maybe it is not deployed, or project's id in rebel-remote.xml file is different.
com.zeroturnaround.jrebel.remoting.RemotingException: Cannot find such project on the remote server. Maybe it is not deployed, or project's id in rebel-remote.xml file is different.
    at com.zeroturnaround.jrebel.remoting.net.RemotingClient.performHandshake(JRebelRemoting:124)
    at com.zeroturnaround.jrebel.remoting.net.RemotingClient.beginTransaction(JRebelRemoting:77)
    at com.zeroturnaround.jrebel.remoting.Transaction.begin(JRebelRemoting:108)
    at com.zeroturnaround.jrebel.remoting.TransactionGroup.begin(JRebelRemoting:35)
    at org.zeroturnaround.eclipse.jrebel.remoting.builder.RemotingSyncPerformer.initSynchronization(RemotingSyncPerformer.java:58)
    at org.zeroturnaround.eclipse.jrebel.remoting.builder.ManualBuilder.synchronizeProject(ManualBuilder.java:57)
    at org.zeroturnaround.eclipse.jrebel.remoting.actions.SyncNowAction$1.run(SyncNowAction.java:124)
    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

【问题讨论】:

  • 可能没有部署,或者rebel-remote.xml文件中的项目id不一样?

标签: java tomcat jrebel


【解决方案1】:

正如 Stefan 所提到的,确保部署的应用程序也有 rebel-remote.xml - 对于 .war 文件或 .jar 文件的根目录,它应该在 WEB-INF/classes 内。如果确实存在,请确保工作空间和部署的应用程序中的 id-s 相同。如果你有多个模块,每个模块都应该有唯一的 remote-id。

另一件事是确保您确实需要使用远程处理 - 如果您从同一台机器启动服务器,则不会,因为远程处理适用于服务器位于不同机器或 VM 中的情况。从同一台机器开始,无论是否在您的 IDE 之外,您只需要确保部署的应用程序有 rebel.xmls 包含由 IDE 编译的类文件的路径。

如果一切都失败了,请联系 support@zeroturnaround.com

【讨论】:

  • 谢谢。比如说,我有 10 个不同的项目(并且我正在访问一个虚拟机),当我点击 JRebel->Enable JRebel 性质时,rebel.xml(和 rebel-remote.xml,当我启用 Remote 时)在同一个项目上生成pom.xml 中的文件夹。它应该在 src/main/resources 中生成。知道为什么,它没有在 src 中生成(我也尝试过执行特定于模块的构建/完整(Maven)构建)。请帮忙
猜你喜欢
  • 1970-01-01
  • 2016-09-15
  • 2020-11-16
  • 1970-01-01
  • 2018-03-31
  • 1970-01-01
  • 1970-01-01
  • 2011-08-23
  • 1970-01-01
相关资源
最近更新 更多