quarkusio/quarkus · error · MojoExecutionException

Failed to initialize Quarkus extension resolver

Error message

Failed to initialize Quarkus extension resolver

What it means

initExtensionCatalogResolver creates the extension catalog resolver via QuarkusProjectHelper.getCatalogResolver, which itself resolves registry metadata. A RegistryResolutionException there is wrapped in this MojoExecutionException, meaning the extension resolver could not be initialized at all.

Source

Thrown at devtools/maven/src/main/java/io/quarkus/maven/QuarkusProjectMojoBase.java:159

        return ToolsUtils.mergePlatforms(collectImportedPlatforms(), catalogArtifactResolver());
    }

    protected ExtensionCatalogResolver getExtensionCatalogResolver() throws MojoExecutionException {
        return catalogResolver == null ? catalogResolver = initExtensionCatalogResolver() : catalogResolver;
    }

    private ExtensionCatalogResolver initExtensionCatalogResolver() throws MojoExecutionException {
        if (!QuarkusProjectHelper.isRegistryClientEnabled()) {
            return ExtensionCatalogResolver.empty();
        }
        final ExtensionCatalogResolver catalogResolver;
        try {
            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,

View on GitHub (pinned to e1c734241f)

Solutions

  1. Ensure network access to registry.quarkus.io or configure an accessible mirror/quarkus.registry URL
  2. Validate the quarkus.registry configuration syntax in .quarkus/config.yaml
  3. Clear the corrupted local registry cache (~/.quarkus) and rerun the goal
  4. Rerun with registry refresh enabled to force a fresh registry fetch
Defensive patterns

Strategy: try-catch

Validate before calling

// confirm registry config file parses and endpoints resolve before running
// grep quarkus.registry .quarkus/config.yaml
// nslookup registry.quarkus.io

Try / catch

try {
    mojo.execute();
} catch (MojoExecutionException e) {
    if (e.getMessage().equals("Failed to initialize Quarkus extension resolver") && e.getCause() instanceof RegistryResolutionException) {
        // fix registry config/connectivity, clear ~/.quarkus cache, retry with refresh
    } else {
        throw e;
    }
}

Prevention

When it happens

Trigger: Any Quarkus MoJo calling getExtensionCatalogResolver (during execute or catalog resolution) when the initial registry bootstrap fails — e.g. the registry config cannot be read or the default registry descriptor cannot be fetched.

Common situations: First offline run with no cached registry data; invalid quarkus.registry configuration (bad URL, malformed XML); DNS or proxy failures reaching the registry host; corrupted ~/.quarkus cache directory.

Related errors


AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05). Data as JSON: /api/errors/5adb30fe12d4814f. Report an issue: GitHub.