{"record":{"id":"59c4c420a2cc495a","repo":"quarkusio/quarkus","slug":"resolution-of-annotationprocessorpath-dependencies","errorCode":null,"errorMessage":"Resolution of annotationProcessorPath dependencies failed: <message>","messagePattern":"Resolution of annotationProcessorPath dependencies failed: <message>","errorType":"exception","errorClass":"MojoExecutionException","httpStatus":null,"severity":"error","filePath":"devtools/maven/src/main/java/io/quarkus/maven/DevMojo.java","lineNumber":948,"sourceCode":"        }\n        var versionConstraints = getAnnotationProcessorPathsDepMgmt(pluginConfig);\n        Xpp3Dom[] paths = annotationProcessorPaths.getChildren(\"path\");\n        Set<File> elements = new LinkedHashSet<>();\n        try {\n            List<org.eclipse.aether.graph.Dependency> dependencies = convertToDependencies(paths);\n            CollectRequest collectRequest = new CollectRequest(dependencies, versionConstraints,\n                    project.getRemoteProjectRepositories());\n            DependencyRequest dependencyRequest = new DependencyRequest();\n            dependencyRequest.setCollectRequest(collectRequest);\n            DependencyResult dependencyResult = repoSystem.resolveDependencies(session.getRepositorySession(),\n                    dependencyRequest);\n\n            for (ArtifactResult resolved : dependencyResult.getArtifactResults()) {\n                elements.add(resolved.getArtifact().getFile());\n            }\n            return elements;\n        } catch (Exception e) {\n            throw new MojoExecutionException(\n                    \"Resolution of annotationProcessorPath dependencies failed: \" + e.getLocalizedMessage(), e);\n        }\n    }\n\n    private List<org.eclipse.aether.graph.Dependency> getAnnotationProcessorPathsDepMgmt(Xpp3Dom pluginConfig) {\n        final Xpp3Dom useDepMgmt = pluginConfig.getChild(\"annotationProcessorPathsUseDepMgmt\");\n        if (useDepMgmt == null || !Boolean.parseBoolean(useDepMgmt.getValue())) {\n            return List.of();\n        }\n        var dm = project.getDependencyManagement();\n        if (dm == null) {\n            return List.of();\n        }\n        return getProjectAetherDependencyManagement();\n    }\n\n    private List<org.eclipse.aether.graph.Dependency> convertToDependencies(Xpp3Dom[] paths) throws MojoExecutionException {\n        List<org.eclipse.aether.graph.Dependency> dependencies = new ArrayList<>();","sourceCodeStart":930,"sourceCodeEnd":966,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/devtools/maven/src/main/java/io/quarkus/maven/DevMojo.java#L930-L966","documentation":"DevMojo resolves the project's annotationProcessorPaths so generated sources are visible in dev mode. If the Aether dependency resolution of those processor artifacts fails, it throws MojoExecutionException with this message and the resolver's localized error message. This typically means a compiler-plugin annotation processor dependency cannot be resolved.","triggerScenarios":"Configuring maven-compiler-plugin annotationProcessorPaths with an artifact that is missing from repositories, has no version (and dep management not enabled), or is unresolvable offline; corrupt local cache entry for the processor.","commonSituations":"Lombok/MapStruct/QueryDSL processor declared with a version absent from the repo; annotationProcessorPathsUseDepMgmt not enabled while versions come from dependencyManagement; proxy blocking download; snapshot processor no longer published.","solutions":["Add explicit <version> to each annotationProcessorPath entry, or set annotationProcessorPathsUseDepMgmt=true to inherit versions from dependencyManagement.","Run with -U to refresh stale metadata and delete corrupt ~/.m2/repository entries for the failing processor.","Verify the processor artifact/version exists in the configured repositories (check network/proxy/credentials).","Read the chained message for the exact unresolvable artifact and fix its coordinates."],"exampleFix":"// before\n<annotationProcessorPath>\n  <groupId>org.projectlombok</groupId>\n  <artifactId>lombok</artifactId>\n</annotationProcessorPath>\n// after\n<annotationProcessorPath>\n  <groupId>org.projectlombok</groupId>\n  <artifactId>lombok</artifactId>\n  <version>1.18.34</version>\n</annotationProcessorPath>","handlingStrategy":"validation","validationCode":"// ensure each annotationProcessorPath has a resolvable version\n// pre-flight resolve check\nmvn dependency:resolve -DincludeArtifactIds=lombok,mapstruct-processor -U","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Declare explicit versions for every annotationProcessorPath.","Set annotationProcessorPathsUseDepMgmt=true when versions come from dependencyManagement.","Keep processor artifacts in reachable repositories.","Clean corrupt ~/.m2 entries when resolution fails oddly."],"tags":["maven","annotation-processor","dependency-resolution","quarkus"],"backgroundTag":"dependency-resolution-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"}