quarkusio/quarkus · critical · MojoExecutionException
Failed to bootstrap the application
Error message
Failed to bootstrap the application
What it means
This MojoExecutionException is thrown by QuarkusBootstrapProvider.doBootstrap when the CuratedApplication bootstrap fails. The plugin builds a QuarkusBootstrap from the Maven project and calls bootstrap(); any BootstrapException raised during curation/application bootstrap (dependency resolution failures, invalid configuration, augmentation errors) is wrapped in this generic 'Failed to bootstrap the application' message, with the root cause attached as the cause.
Source
Thrown at devtools/maven/src/main/java/io/quarkus/maven/QuarkusBootstrapProvider.java:357
.setIsolateDeployment(true)
.setBaseClassLoader(getClass().getClassLoader())
.setBuildSystemProperties(getBuildSystemProperties(mojo, true))
.setProjectRoot(mojo.baseDir().toPath())
.setBaseName(mojo.finalName())
.setOriginalBaseName(mojo.mavenProject().getBuild().getFinalName())
.setTargetDirectory(mojo.buildDir().toPath())
.setForcedDependencies(forcedDependencies)
.setDependencyInfoProvider(() -> DependencyInfoProvider.builder()
.setMavenModelResolver(EffectiveModelResolver.of(artifactResolver(mojo, mode)))
.build());
try {
if (builderCustomizer != null) {
builderCustomizer.accept(builder);
}
return builder.build().bootstrap();
} catch (BootstrapException e) {
throw new MojoExecutionException("Failed to bootstrap the application", e);
}
}
/**
* Collects properties from a project configuration that are relevant for the build.
* The {@code quarkusOnly} argument indicates whether only {@code quarkus.*} properties
* should be collected, which is currently set to {@code true} for building an application.
* {@code quarkusOnly} is set to {@code false} when initializing configuration for
* source code generators, for example to enable {@code avro.*} properties, etc.
*
* @param mojo Mojo for which the properties should be collected
* @param quarkusOnly whether to collect only 'quarkus.*' properties
* @return properties from a project configuration that are relevant for the build
* @throws MojoExecutionException in case of a failure
*/
public Properties getBuildSystemProperties(QuarkusBootstrapMojo mojo, boolean quarkusOnly)
throws MojoExecutionException {
final Properties effectiveProperties = new Properties();View on GitHub (pinned to e1c734241f)
Solutions
- Read the 'Caused by: BootstrapException' chain in the Maven output to find the real root cause (the wrapper message is generic)
- Run with -X or -e to get the full stack trace and identify which dependency or config item failed
- Fix dependency resolution problems (mvn -U, remove corrupt ~/.m2 entries, verify repository access)
- Correct invalid quarkus.* configuration in application.properties or the POM
- Verify all Quarkus extensions and the Quarkus BOM share the same version
Example fix
// pom.xml — mismatched extension versions causing curation failure // before <dependency><groupId>io.quarkus</groupId><artifactId>quarkus-resteasy</artifactId><version>3.2.0.Final</version></dependency> // after — use the BOM and omit individual versions <dependencyManagement><dependencies><dependency><groupId>io.quarkus</groupId><artifactId>quarkus-bom</artifactId><version>3.15.1</version><type>pom</type><scope>import</scope></dependency></dependencies></dependencyManagement> <dependency><groupId>io.quarkus</groupId><artifactId>quarkus-resteasy</artifactId></dependency>
Defensive patterns
Strategy: try-catch
Validate before calling
// Pre-flight: validate dependencies and config before bootstrapping mvn dependency:resolve -U mvn -q help:evaluate -Dexpression=project.artifactId -DforceStdout // Ensure all quarkus.* properties referenced in application.properties exist // and extension versions align with the imported quarkus-bom version.
Try / catch
try {
mojo.execute();
} catch (MojoExecutionException e) {
if (e.getMessage().startsWith("Failed to bootstrap the application")) {
Throwable root = e;
while (root.getCause() != null) { root = root.getCause(); }
getLog().error("Bootstrap failed: " + root.getMessage());
// fix dependency/config issue indicated by the root cause
} else { throw e; }
} Prevention
- Import quarkus-bom and never pin individual Quarkus extension versions manually
- Run mvn -U and clear corrupt ~/.m2 artifacts when builds fail after upgrades
- Keep all quarkus.* configuration validated (use quarkus config generation/schema checks)
- Read the full cause chain before changing anything — the wrapper message is generic
- Pin a reproducible Maven setup (settings.xml, mirrors) in CI
When it happens
Trigger: A Quarkus Maven mojo (quarkus:dev, quarkus:build, quarkus:generate-code, etc.) invokes bootstrapApplication -> doBootstrap, and builder.build().bootstrap() throws a BootstrapException, e.g. because the application model could not be curated, a dependency is unresolvable, or extension augmentation failed.
Common situations: Corrupt or missing local Maven repository artifacts; incompatible extension versions on the classpath; invalid quarkus.* configuration values; appArtifactCoords pointing to an artifact that cannot be resolved; broken parent/dependency POMs; network/repository outages during dependency download.
Related errors
- Quarkus code generation phase has failed
- Failed to bootstrap Quarkus application
- Failed to ensure Quarkus Maven version compatibility
- <detected Maven version> is not supported, it must be in <re
- Failed to create application model resolver for
AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05).
Data as JSON: /api/errors/b49d544959cdb3e2.
Report an issue: GitHub.