Skip to content

Commit

Permalink
Merge pull request #480 from seancorfield/better-exception-reporting
Browse files Browse the repository at this point in the history
Print stack trace for "unexpected" exception
  • Loading branch information
micha committed Jul 29, 2016
2 parents d66a065 + 3ac2280 commit 38a72ca
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion boot/base/src/main/java/boot/App.java
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,10 @@ public class App {
core.get().invoke("boot.main/-main", nextId(), worker.get(), hooks, args);
return -1; }
catch (Throwable t) {
return (t instanceof Exit) ? Integer.parseInt(t.getMessage()) : -2; }
if (t instanceof Exit) return Integer.parseInt(t.getMessage());
System.out.println("Boot failed to start:");
t.printStackTrace();
return -2; }
finally {
for (Runnable h : hooks) h.run();
try { core.get().close(); }
Expand Down

0 comments on commit 38a72ca

Please sign in to comment.