We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 159ef8f commit ec7d638Copy full SHA for ec7d638
spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/RunMojo.java
@@ -41,8 +41,12 @@ public class RunMojo extends AbstractRunMojo {
41
@Override
42
protected void runWithForkedJvm(List<String> args) throws MojoExecutionException {
43
try {
44
- new RunProcess(new JavaExecutable().toString()).run(true,
+ int exitCode = new RunProcess(new JavaExecutable().toString()).run(true,
45
args.toArray(new String[args.size()]));
46
+ if (exitCode != 0) {
47
+ throw new MojoExecutionException(
48
+ "Application finished with non-zero exit code: " + exitCode);
49
+ }
50
}
51
catch (Exception ex) {
52
throw new MojoExecutionException("Could not exec java", ex);
0 commit comments