{"record":{"id":"b49d544959cdb3e2","repo":"quarkusio/quarkus","slug":"failed-to-bootstrap-the-application","errorCode":null,"errorMessage":"Failed to bootstrap the application","messagePattern":"Failed to bootstrap the application","errorType":"exception","errorClass":"MojoExecutionException","httpStatus":null,"severity":"critical","filePath":"devtools/maven/src/main/java/io/quarkus/maven/QuarkusBootstrapProvider.java","lineNumber":357,"sourceCode":"                    .setIsolateDeployment(true)\n                    .setBaseClassLoader(getClass().getClassLoader())\n                    .setBuildSystemProperties(getBuildSystemProperties(mojo, true))\n                    .setProjectRoot(mojo.baseDir().toPath())\n                    .setBaseName(mojo.finalName())\n                    .setOriginalBaseName(mojo.mavenProject().getBuild().getFinalName())\n                    .setTargetDirectory(mojo.buildDir().toPath())\n                    .setForcedDependencies(forcedDependencies)\n                    .setDependencyInfoProvider(() -> DependencyInfoProvider.builder()\n                            .setMavenModelResolver(EffectiveModelResolver.of(artifactResolver(mojo, mode)))\n                            .build());\n\n            try {\n                if (builderCustomizer != null) {\n                    builderCustomizer.accept(builder);\n                }\n                return builder.build().bootstrap();\n            } catch (BootstrapException e) {\n                throw new MojoExecutionException(\"Failed to bootstrap the application\", e);\n            }\n        }\n\n        /**\n         * Collects properties from a project configuration that are relevant for the build.\n         * The {@code quarkusOnly} argument indicates whether only {@code quarkus.*} properties\n         * should be collected, which is currently set to {@code true} for building an application.\n         * {@code quarkusOnly} is set to {@code false} when initializing configuration for\n         * source code generators, for example to enable {@code avro.*} properties, etc.\n         *\n         * @param mojo Mojo for which the properties should be collected\n         * @param quarkusOnly whether to collect only 'quarkus.*' properties\n         * @return properties from a project configuration that are relevant for the build\n         * @throws MojoExecutionException in case of a failure\n         */\n        public Properties getBuildSystemProperties(QuarkusBootstrapMojo mojo, boolean quarkusOnly)\n                throws MojoExecutionException {\n            final Properties effectiveProperties = new Properties();","sourceCodeStart":339,"sourceCodeEnd":375,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/devtools/maven/src/main/java/io/quarkus/maven/QuarkusBootstrapProvider.java#L339-L375","documentation":"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.","triggerScenarios":"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.","commonSituations":"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.","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"],"exampleFix":"// pom.xml — mismatched extension versions causing curation failure\n// before\n<dependency><groupId>io.quarkus</groupId><artifactId>quarkus-resteasy</artifactId><version>3.2.0.Final</version></dependency>\n// after — use the BOM and omit individual versions\n<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>\n<dependency><groupId>io.quarkus</groupId><artifactId>quarkus-resteasy</artifactId></dependency>","handlingStrategy":"try-catch","validationCode":"// Pre-flight: validate dependencies and config before bootstrapping\nmvn dependency:resolve -U\nmvn -q help:evaluate -Dexpression=project.artifactId -DforceStdout\n// Ensure all quarkus.* properties referenced in application.properties exist\n// and extension versions align with the imported quarkus-bom version.","typeGuard":null,"tryCatchPattern":"try {\n    mojo.execute();\n} catch (MojoExecutionException e) {\n    if (e.getMessage().startsWith(\"Failed to bootstrap the application\")) {\n        Throwable root = e;\n        while (root.getCause() != null) { root = root.getCause(); }\n        getLog().error(\"Bootstrap failed: \" + root.getMessage());\n        // fix dependency/config issue indicated by the root cause\n    } else { throw e; }\n}","preventionTips":["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"],"tags":["maven","bootstrap","quarkus","build"],"backgroundTag":"application-bootstrap-failed","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-12T22:17:10.623Z"}