当我运行我的Java代码时,我得到了错误“进程已完成,退出代码为1”。我正在使用Intellij IDEA 2018.3。下面是我得到的错误日志。

发布于 2019-11-06 02:10:12
在Intellij Idea中运行Java应用程序时,在程序执行之后,JVM将退出代码打印到控制台。如果程序在没有任何异常的情况下终止,则打印退出代码0。否则,可能会输出任何有符号整数。
发布于 2021-06-22 01:11:39
要获得有关退出代码的更多信息,请尝试将try catch放在SpringApplication.run()函数周围,如下所示:
try
{
SpringApplication.run(Application.class, args);
}
catch (Throwable throwable)
{
System.out.println(throwable.toString());
throwable.printStackTrace();
}https://stackoverflow.com/questions/55791675
复制相似问题