quarkusio/quarkus · critical
Failed to start Quarkus
Error message
Failed to start Quarkus
What it means
When StartupActionImpl.run() invokes the application's main class reflectively, the invoked code itself throws. Non-Exception Throwables (e.g. Errors like NoClassDefFoundError, StackOverflowError) cannot be rethrown as Exception, so they are wrapped in RuntimeException("Failed to start Quarkus") with the original cause attached.
Source
Thrown at core/deployment/src/main/java/io/quarkus/runner/bootstrap/StartupActionImpl.java:450
}
// This will read the state of the curated application at the time of closing;
// If the caller of close knows that the 'next' application shares a curated application, it can set eligible for reuse to true
if (!curatedApplication.isEligibleForReuse()) {
if (curatedApplication.getQuarkusBootstrap().getMode() == QuarkusBootstrap.Mode.TEST
&& !curatedApplication.getQuarkusBootstrap().isAuxiliaryApplication()) {
//for tests, we just always shut down the curated application, as it is only used once
//dev mode might be about to restart, so we leave it
curatedApplication.close();
}
}
}
}
}, runtimeClassLoader);
} catch (InvocationTargetException e) {
if (e.getCause() instanceof Exception) {
throw (Exception) e.getCause();
}
throw new RuntimeException("Failed to start Quarkus", e.getCause());
} finally {
Thread.currentThread().setContextClassLoader(old);
}
}
@Override
public QuarkusClassLoader getClassLoader() {
return runtimeClassLoader;
}
@Override
public Map<String, String> getOrInitialiseDevServicesProperties() {
ensureDevServicesStarted();
return devServicesProperties;
}
@OverrideView on GitHub (pinned to e1c734241f)
Solutions
- Read the wrapped getCause() to find the real Error and fix that first
- Check for dependency version conflicts (mvn dependency:tree) causing NoClassDefFoundError/LinkageError
- Increase JVM memory if the cause is OutOfMemoryError
- Clean and rebuild to eliminate stale/incompatible compiled classes
Defensive patterns
Strategy: try-catch
Validate before calling
// preflight: check for known conflicting dependencies // mvn dependency:tree | grep -i conflicting-library
Try / catch
try { action.run(); } catch (RuntimeException e) { if ("Failed to start Quarkus".equals(e.getMessage())) { Throwable cause = e.getCause(); /* handle Error e.g. NoClassDefFoundError */ } else { throw e; } } Prevention
- Always inspect getCause() — the real failure is an Error thrown by the app
- Keep dependency versions aligned across modules
- Watch JVM memory limits during startup
- Run mvn clean when class/linkage errors appear
When it happens
Trigger: The application's startable main method throws an Error (not an Exception) during startup — e.g. NoClassDefFoundError from a missing or conflicting dependency, LinkageError from incompatible classes, OutOfMemoryError.
Common situations: Duplicate/incompatible library versions causing linkage errors at startup; JVM-level failures (OOM, metaspace) during boot; native-image-incompatible classes touched at startup.
Related errors
- Quarkus failed to start up
- Unable to find top command. Ensure you have a @CommandDefini
- Quarkus initialization error
- Failed to find any non-blocking provider for startup actions
- The 'quarkus.hibernate-orm.mapping.format.global' configurat
AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05).
Data as JSON: /api/errors/19f0913717406655.
Report an issue: GitHub.