IntelliJ Web项目中的JRebel,404错误

问题描述 投票:0回答:1

我有一个我最初在Eclipse中创建的JEE Web项目。我使用Eclipse jrebel插件进行调试,一切正常。现在我已将其迁移到IntelliJ,并使用JRebel插件。当我运行它时,该项目似乎部署得很好。启动代码上的断点被命中。但是,当我在浏览器中打开主页时,出现错误“请求不被服务器理解”。 (404)”。 REST调用无效。我没有尝试对代码进行任何正在进行的更改,只是想让它先运行。

我看过jrebel.log,那里没什么特别的。

intellij-idea web-deployment jrebel
1个回答
0
投票

我找到了解决方案 - 不要使用IntelliJ生成的rebel.xml文件,而是使用maven插件。将其添加到父pom中的maven文件中 -

<build>
...
 <plugin>
                    <groupId>org.zeroturnaround</groupId>
                    <artifactId>jrebel-maven-plugin</artifactId>
                    <version>1.1.9</version>
                    <executions>
                          <execution>
                                <id>generate-rebel-xml</id>
                                <phase>process-resources</phase>
                                <goals>
                                      <goal>generate</goal>
                                </goals>
                          </execution>
                    </executions>
              </plugin>
...
</build>
© www.soinside.com 2019 - 2024. All rights reserved.