quarkusio/quarkus · error · MojoExecutionException
Couldn't resolve the Quarkus platform catalog since none of
Error message
Couldn't resolve the Quarkus platform catalog since none of the Quarkus extension registries are available
What it means
This MojoExecutionException is thrown by QuarkusProjectMojoBase.getImportedPlatforms when a Maven goal (e.g. quarkus:add-extension, quarkus:list-platforms) needs the Quarkus platform catalog but the configured ExtensionCatalogResolver has no extension registries available. Registries come from quarkus.registry settings or the default registry; without them, platform BOM resolution is impossible. It is thrown only when the project has no pom.xml file (project.getFile() == null) and no explicit BOM coordinates were given, since registry-based resolution is then the only source of the platform.
Source
Thrown at devtools/maven/src/main/java/io/quarkus/maven/QuarkusProjectMojoBase.java:172
catalogResolver = QuarkusProjectHelper.getCatalogResolver(catalogArtifactResolver(), getMessageWriter());
if (refresh) {
catalogResolver.clearRegistryCache();
}
} catch (RegistryResolutionException e) {
throw new MojoExecutionException("Failed to initialize Quarkus extension resolver", e);
}
return catalogResolver;
}
protected List<ArtifactCoords> getImportedPlatforms() throws MojoExecutionException {
if (importedPlatforms == null) {
if (project.getFile() == null) {
if (bomGroupId == null && bomArtifactId == null && bomVersion == null) {
return List.of();
}
final ExtensionCatalogResolver catalogResolver = getExtensionCatalogResolver();
if (!catalogResolver.hasRegistries()) {
throw new MojoExecutionException(
"Couldn't resolve the Quarkus platform catalog since none of the Quarkus extension registries are available");
}
ArtifactCoords platformBom;
try {
platformBom = getSingleMatchingBom(bomGroupId, bomArtifactId, bomVersion,
getExtensionCatalogResolver().resolvePlatformCatalog());
} catch (RegistryResolutionException e) {
throw new MojoExecutionException("Failed to resolve the catalog of Quarkus platforms", e);
}
if (platformBom == null && bomVersion != null) {
platformBom = ArtifactCoords.pom(
bomGroupId == null ? ToolsConstants.DEFAULT_PLATFORM_BOM_GROUP_ID : bomGroupId,
bomArtifactId == null ? ToolsConstants.DEFAULT_PLATFORM_BOM_ARTIFACT_ID : bomArtifactId,
bomVersion);
}
return importedPlatforms = platformBom == null ? List.of() : List.of(platformBom);
}
importedPlatforms = collectImportedPlatforms();View on GitHub (pinned to e1c734241f)
Solutions
- Run the goal from a directory containing a pom.xml, or pass explicit BOM coordinates (-DplatformGroupId/-DplatformArtifactId/-DplatformVersion) so registry resolution is skipped
- Enable the Quarkus registry client (remove -DquarkusRegistryClient=false) or add a registry to the Quarkus registry config (quarkus.assistant / registry config yaml)
- Check network/proxy settings so the default Quarkus registry (registry.quarkus.io) is reachable
- As a fallback, pin the platform explicitly: -DbomGroupId=io.quarkus.platform -DbomArtifactId=quarkus-bom -DbomVersion=<version>
Example fix
// before mvn io.quarkus:quarkus-maven-plugin:add-extension -Dextensions="rest" (run in empty dir) // after mvn io.quarkus:quarkus-maven-plugin:add-extension -Dextensions="rest" -DbomGroupId=io.quarkus.platform -DbomArtifactId=quarkus-bom -DbomVersion=3.8.1
Defensive patterns
Strategy: validation
Validate before calling
if (!new File("pom.xml").exists() && (System.getProperty("bomVersion") == null)) {
// require explicit platform coordinates or cd into a project directory first
}
// also check registry availability:
// boolean ok = quarkusProject.getExtensionCatalogResolver().hasRegistries(); Try / catch
try { mojo getImportedPlatforms... } catch (MojoExecutionException e) { if (e.getMessage().contains("registries are available")) { /* rerun with -DbomGroupId/-DbomArtifactId/-DbomVersion */ } } Prevention
- Run Quarkus mojos from a directory containing a valid pom.xml
- Keep the Quarkus registry client enabled and registries configured
- Pin explicit platform coordinates in CI to avoid registry dependency
- Document proxy/whitelist requirements for registry.quarkus.io
When it happens
Trigger: Running a Quarkus Maven mojo outside a project directory (or with no pom.xml) while no extension registry is configured or reachable, e.g. registry client disabled via -DquarkusRegistryClient=false or no registry in ~/.quarkus/config.yaml.
Common situations: Running quarkus:add-extension / create-extension style goals in an empty directory; CI environments with the registry client disabled; corporate proxies blocking registry access; missing registry config in ~/.m2/settings.xml or quarkus registry config.
Related errors
- Failed to resolve the catalog of Quarkus platforms
- Unsupported format: ${format}
- Malformed URL: + url
- Either the `extension` or `extensions` parameter must be set
- Cannot specify both class and method name
AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05).
Data as JSON: /api/errors/44c229142d83e3c9.
Report an issue: GitHub.