diff --git a/spring-boot/src/main/java/org/springframework/boot/SpringApplication.java b/spring-boot/src/main/java/org/springframework/boot/SpringApplication.java index b307aceaa5..147239f69d 100644 --- a/spring-boot/src/main/java/org/springframework/boot/SpringApplication.java +++ b/spring-boot/src/main/java/org/springframework/boot/SpringApplication.java @@ -330,7 +330,7 @@ public class SpringApplication { } return context; } - catch (Exception ex) { + catch (Throwable ex) { try { for (SpringApplicationRunListener runListener : runListeners) { finishWithException(runListener, context, ex); @@ -696,7 +696,7 @@ public class SpringApplication { } private void finishWithException(SpringApplicationRunListener runListener, - ConfigurableApplicationContext context, Exception exception) { + ConfigurableApplicationContext context, Throwable exception) { try { runListener.finished(context, exception); }