Error occurred in starting fork, check output in log

Maven打包错误解决方案

今天在使用maven package的时候遇到这个报错,通过在pom中添加以下插件解决:

<build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>3.0.0-M3</version>
                <configuration>
                    <forkCount>0</forkCount>
                    <testFailureIgnore>true</testFailureIgnore>
                </configuration>
            </plugin>
        </plugins>
    </build>

 

[INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1.500 s [INFO] Finished at: 2025-07-24T10:41:36+08:00 [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.5.2:test (default-test) on project common: [ERROR] [ERROR] See D:\Git_Code\AI-Interview-dev\common\target\surefire-reports for the individual test results. [ERROR] See dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream. [ERROR] The forked VM terminated without properly saying goodbye. VM crash or System.exit called? [ERROR] Command was cmd.exe /X /C "D:\JDK(OpenJDK21)\jdk-21\bin\java -jar C:\Users\Lenovo\AppData\Local\Temp\surefire9960548804214740057\surefirebooter-20250724104136110_3.jar C:\Users\Lenovo\AppData\Local\Temp\surefire9960548804214740057 2025-07-24T10-41-35_989-jvmRun1 surefire-20250724104136110_1tmp surefire_0-20250724104136110_2tmp" [ERROR] Error occurred in starting fork, check output in log [ERROR] Process Exit Code: 1 [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The forked VM terminated without properly saying goodbye. VM crash or System.exit called? [ERROR] Command was cmd.exe /X /C "D:\JDK(OpenJDK21)\jdk-21\bin\java -jar C:\Users\Lenovo\AppData\Local\Temp\surefire9960548804214740057\surefirebooter-20250724104136110_3.jar C:\Users\Lenovo\AppData\Local\Temp\surefire9960548804214740057 2025-07-24T10-41-35_989-jvmRun1 surefire-20250724104136110_1tmp surefire_0-20250724104136110_2tmp" [ERROR] Error occurred in starting fork, check output in log [ERROR] Process Exit Code: 1 [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:643) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:285) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:250) [ERROR]
07-25
评论 4
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值