quarkusio/quarkus · error · ConfigurationException

Cannot find the Proxy registry configuration '%s'

Error message

Cannot find the Proxy registry configuration '%s'

What it means

Quarkus lets you reference a named proxy configuration registered at build time via quarkus.oidc.proxy... name/registry config. At startup, toProxyOptions looks the name up in the proxy configuration registry; if no registered proxy configuration with that name exists, startup fails with this message containing the requested name.

Source

Thrown at extensions/oidc-common/runtime/src/main/java/io/quarkus/oidc/common/runtime/OidcCommonUtils.java:385

    public static long getConnectionDelayInMillis(OidcCommonConfig oidcConfig) {
        final long connectionDelayInSecs = getConnectionDelay(oidcConfig);
        final long connectionRetryCount = connectionDelayInSecs > 1 ? connectionDelayInSecs / 2 : 1;
        if (connectionRetryCount > 1) {
            LOG.infof("Connecting to OpenId Connect Provider for up to %d times every 2 seconds", connectionRetryCount);
        }
        return connectionDelayInSecs * 1000;
    }

    public static Optional<ProxyOptions> toProxyOptions(OidcCommonConfig.Proxy oidcProxyConfig,
            ProxyConfigurationRegistry proxyConfigurationRegistry) {
        if (oidcProxyConfig.proxyConfigurationName().isEmpty()) {
            return Optional.empty();
        }

        var maybeProxyConfig = proxyConfigurationRegistry.get(oidcProxyConfig.proxyConfigurationName());
        if (maybeProxyConfig.isEmpty()) {
            throw new ConfigurationException("Cannot find the Proxy registry configuration '%s'"
                    .formatted(oidcProxyConfig.proxyConfigurationName().get()));
        }

        var proxyRegistryConfig = maybeProxyConfig.get().assertHttpType();
        final String hostProperty = proxyRegistryConfig.host();
        final int portProperty = proxyRegistryConfig.port();
        final Optional<String> usernameProperty = proxyRegistryConfig.username();
        final Optional<String> passwordProperty = proxyRegistryConfig.password();
        final Optional<Duration> proxyConnectTimeoutProperty = proxyRegistryConfig.proxyConnectTimeout();
        if (proxyRegistryConfig.nonProxyHosts().isPresent()) {
            throw new ConfigurationException(
                    "The OIDC proxy configuration currently does not support the 'quarkus.proxy.\""
                            + oidcProxyConfig.proxyConfigurationName().get() + "\".non-proxy-hosts' property");
        }

        JsonObject jsonOptions = new JsonObject();
        // Vert.x Client currently does not expect a host having a scheme but keycloak-authorization expects scheme and host.
        // Having a dedicated scheme property is probably better, but since it is property is not taken into account in Vertx Client

View on GitHub (pinned to e1c734241f)

Solutions

  1. Fix the name so it exactly matches a registered proxy configuration (check quarkus.oidc.proxy.* and the registry @RegistryConfig name)
  2. Add the missing proxy registry configuration block that the name refers to
  3. Remove the proxy configuration name property if no proxy is needed
  4. Confirm the build-time config supplying the registry entries is present in the current profile

Example fix

# before (references non-existent registry entry)
quarkus.oidc.proxy.configuration-name=corp-proxy

# after (register the configuration it points to)
quarkus.oidc.proxy.configuration-name=corp-proxy
quarkus.http.proxy... # or ensure the @RegistryConfig block named 'corp-proxy' exists
Defensive patterns

Strategy: validation

Validate before calling

String proxyName = ConfigProvider.getConfig().getOptionalValue("quarkus.oidc.proxy.configuration-name", String.class).orElse(null);
if (proxyName != null && !KNOWN_PROXY_REGISTRY_NAMES.contains(proxyName))
    throw new IllegalStateException("Unknown proxy registry configuration: " + proxyName);

Try / catch

try {
    start();
} catch (ConfigurationException e) {
    if (e.getMessage().startsWith("Cannot find the Proxy registry configuration")) log.error("Register or correct the proxy configuration name");
    throw e;
}

Prevention

When it happens

Trigger: oidcProxyConfig.proxyConfigurationName() is set to a name that proxyConfigurationRegistry.get(...) does not contain, when building the HTTP client options (via proxyOpt).

Common situations: Typo in the proxy configuration name; the @RegistryConfig proxy configuration block was removed or renamed; extension providing the proxy registration is missing so registry is empty; case-sensitivity mismatch in the name.

Related errors


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