【发布时间】:2014-06-09 05:11:39
【问题描述】:
请帮我解决这个问题。我不太明白日志中的错误是什么意思。
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 21.749s
[INFO] Finished at: Thu Apr 24 10:10:20 IST 2014
[INFO] Final Memory: 15M/37M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.15:test (default-test) on project samples.simpleforwarding: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.15:test failed: The forked VM terminated without saying properly goodbye. VM crash or System.exit called ?
[ERROR] Command wascmd.exe /X /C ""C:\Program Files\Java\jdk1.7.0_55\jre\bin\java" -Xmx1024m -XX:MaxPermSize=256m -jar E:\OpenDayLight\controller\opendaylight\samples\simpleforwarding\target\surefire\surefirebooter53410321571238933.jar E:\OpenDayLight\controller\opendaylight\samples\simpleforwarding\target\surefire\surefire86076271125218001tmp E:\OpenDayLight\controller\opendaylight\samples\simpleforwarding\target\surefire\surefire_01846991116135903536tmp"
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException
【问题讨论】:
-
请按照输出提示使用 -e 和 -X 重新运行 Maven,然后粘贴它提供的内容。另外,您是在构建自己的代码还是现有的库?如果您正在构建自己的代码,您是否在任何地方调用 System.exit(int) ?如果您正在构建现有库,您从哪里获得源代码?
-
@Dylon Edwards:这是一个现有的源代码,用于 SDN 实施的 OpenDayLight 项目。
-
我最近遇到的一个重现该问题的场景是当我从 xml 文件运行测试套件时。如果一个 xml 文件定义了一个不再存在的类,或者引用了一个类的旧的完全限定名已被移动,那么 JVM 将无法加载该类。这会导致您观察到奇怪的消息。查看任何堆栈跟踪可以帮助您识别此类问题,在这种情况下无需传递 -e 或 -X 开关。
-
@astack 解决方案是什么?请您标记答案或写下您自己的答案。
-
你试试这个? ```
```org.apache.maven.plugins maven-surefire-plugin version
标签: java maven-surefire-plugin opendaylight