{"record":{"id":"ec39c92a735151ee","repo":"apache/maven","slug":"the-extension-has-been-relocated-to","errorCode":null,"errorMessage":"The extension {} has been relocated to {}{}","messagePattern":"The extension (.+?) has been relocated to (.+?)(.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"impl/maven-core/src/main/java/org/apache/maven/plugin/internal/DefaultPluginDependenciesResolver.java","lineNumber":198,"sourceCode":"        try {\n            DefaultRepositorySystemSession pluginSession = new DefaultRepositorySystemSession(session);\n            pluginSession.setArtifactDescriptorPolicy(new SimpleArtifactDescriptorPolicy(true, false));\n\n            ArtifactDescriptorRequest request =\n                    new ArtifactDescriptorRequest(pluginArtifact, repositories, REPOSITORY_CONTEXT);\n            request.setTrace(trace);\n            ArtifactDescriptorResult result = repoSystem.readArtifactDescriptor(pluginSession, request);\n\n            for (MavenPluginDependenciesValidator dependenciesValidator : dependenciesValidators) {\n                dependenciesValidator.validate(session, pluginArtifact, result);\n            }\n\n            pluginArtifact = result.getArtifact();\n\n            if (logger.isWarnEnabled() && !result.getRelocations().isEmpty()) {\n                String message =\n                        pluginArtifact instanceof RelocatedArtifact relocated ? \": \" + relocated.getMessage() : \"\";\n                logger.warn(\n                        \"The extension {} has been relocated to {}{}\",\n                        result.getRelocations().get(0),\n                        pluginArtifact,\n                        message);\n            }\n            return resolveInternal(plugin, pluginArtifact, dependencyFilter, repositories, session);\n        } catch (ArtifactDescriptorException e) {\n            throw new PluginResolutionException(plugin, e.getResult().getExceptions(), e);\n        }\n    }\n\n    @Deprecated\n    @Override\n    public DependencyResult resolvePlugin(\n            Plugin plugin,\n            Artifact artifact,\n            DependencyFilter dependencyFilter,\n            List<RemoteRepository> repositories,","sourceCodeStart":180,"sourceCodeEnd":216,"githubUrl":"https://github.com/apache/maven/blob/e4093d4e120eac99d6bdce5ba67cace2f3085c97/impl/maven-core/src/main/java/org/apache/maven/plugin/internal/DefaultPluginDependenciesResolver.java#L180-L216","documentation":"The extension-resolution twin of the plugin relocation warning: DefaultPluginDependenciesResolver reads the artifact descriptor for a core extension declared under <build><extensions> (or -Dmaven.ext.class.path artifacts). If that descriptor contains relocations, Maven warns 'The extension <original> has been relocated to <new>' and proceeds to resolveInternal() with the relocated artifact.","triggerScenarios":"Declaring a <build><extensions><extension> whose coordinates were relocated upstream (e.g. wagon providers, takari/tycho artifacts moved to new groupIds); referencing an old extension version after its project changed coordinates.","commonSituations":"Build-extensions blocks copied from old templates; CI images pinning legacy extension coordinates; dependency audits noticing the actual resolved extension differs from the POM.","solutions":["Update the <extension> coordinates in the POM to the relocated GAV from the warning.","Upgrade the extension to its latest release, which typically lives at the new coordinates.","Verify the extension is still needed at all — many relocated artifacts (e.g. wagon providers) have modern replacements."],"exampleFix":"<!-- before -->\n<build>\n  <extensions>\n    <extension>\n      <groupId>org.apache.maven.wagon</groupId>\n      <artifactId>wagon-ssh-external</artifactId>\n      <version>2.10</version>\n    </extension>\n  </extensions>\n</build>\n\n<!-- after: relocated/current coordinates -->\n<extension>\n  <groupId>org.apache.maven.wagon</groupId>\n  <artifactId>wagon-ssh-external</artifactId>\n  <version>3.5.3</version>\n</extension>","handlingStrategy":"fallback","validationCode":"# guard: verify extension coordinates resolve without relocation\nmvn dependency:get -Dartifact=org.apache.maven.wagon:wagon-ssh-external:3.5.3 \\\n  2>&1 | grep -i relocated && echo 'extension moved; update <extensions> block'","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Review the <build><extensions> block quarterly; drop extensions that are obsolete or relocated.","Prefer modern extension coordinates from current documentation over values inherited from old templates."],"tags":["maven","core-extensions","relocation","artifact-metadata","build-extensions"],"backgroundTag":"maven-artifact-relocated","analyzedSha":"e4093d4e120eac99d6bdce5ba67cace2f3085c97","analyzedAt":"2026-08-21T22:58:24.034Z","schemaVersion":2},"datasetVersion":"2026-08-21T23:17:16.201Z"}