Skip to content

Commit af65e67

Browse files
authored
Merge pull request #47336 from stuartwdouglas/failed-start-logging
Don't use logging on failed start
2 parents 75b67ec + 76f192d commit af65e67

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

core/deployment/src/main/java/io/quarkus/deployment/dev/IsolatedDevModeMain.java

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,11 +132,15 @@ private synchronized void firstStart() {
132132
}
133133
} catch (Exception e) {
134134
close();
135-
log.error("Failed to start quarkus", t);
136-
log.error("Failed to recover after failed start", e);
135+
// Don't use logs here, as logging might not be setup yet
136+
// Resulting in a silent exit
137+
System.err.println("Failed to start quarkus");
138+
t.printStackTrace();
139+
System.err.println("Failed to recover after failed start");
140+
e.printStackTrace();
137141
//this is the end of the road, we just exit
138142
//generally we only hit this if something is already listening on the HTTP port
139-
//or the system config is so broken we can't start HTTP
143+
//or the system config is so broken we can't start HTTP]
140144
System.exit(1);
141145
}
142146
}

0 commit comments

Comments
 (0)