quarkusio/quarkus · error · ConfigurationException

Must provide the Signing Domain Identifier (sdid).

Error message

Must provide the Signing Domain Identifier (sdid).

What it means

When DKIM signing is configured for a mailer, Mailers converts DkimSignOptionsConfig into Vert.x DKIMSignOptions. The Signing Domain Identifier (sdid) is mandatory for DKIM; if config lacks it, toVertxDkimSignOptions throws this ConfigurationException during mailer configuration.

Source

Thrown at extensions/mailer/runtime/src/main/java/io/quarkus/mailer/runtime/Mailers.java:173

        }
        // Do not create a shared instance, as we want separated connection pool for each SMTP servers.
        return clientBuilder.build();
    }

    private CredentialsProvider findCredentialsProvider(String mailerName, String beanName) {
        try {
            return CredentialsProviderFinder.find(beanName);
        } catch (Exception e) {
            throw new ConfigurationException("Unable to find credentials provider for the mailer " + mailerName + ".", e);
        }
    }

    private io.vertx.ext.mail.DKIMSignOptions toVertxDkimSignOptions(DkimSignOptionsConfig optionsConfig) {
        DKIMSignOptions vertxDkimOptions = new io.vertx.ext.mail.DKIMSignOptions();

        String sdid = optionsConfig.sdid()
                .orElseThrow(() -> {
                    throw new ConfigurationException("Must provide the Signing Domain Identifier (sdid).");
                });
        vertxDkimOptions.setSdid(sdid);

        String selector = optionsConfig.selector()
                .orElseThrow(() -> {
                    throw new ConfigurationException("Must provide the selector.");
                });
        vertxDkimOptions.setSelector(selector);

        if (optionsConfig.auid().isPresent()) {
            vertxDkimOptions.setAuid(optionsConfig.auid().get());
        }

        if (optionsConfig.bodyLimit().isPresent()) {
            int bodyLimit = optionsConfig.bodyLimit().getAsInt();
            vertxDkimOptions.setBodyLimit(bodyLimit);
        }

View on GitHub (pinned to e1c734241f)

Solutions

  1. Add the signing domain: quarkus.mailer.dkim.sdid=example.com (the domain that published the DKIM public key).
  2. If DKIM is not intended, remove all quarkus.mailer.dkim.* properties so DKIM setup is skipped entirely.
  3. Check config file indentation/structure so sdid really sits inside the dkim map.

Example fix

// before
quarkus.mailer.dkim.selector=s1
quarkus.mailer.dkim.private-key=classpath:dkim.pem

// after
quarkus.mailer.dkim.sdid=example.com
quarkus.mailer.dkim.selector=s1
quarkus.mailer.dkim.private-key=classpath:dkim.pem
Defensive patterns

Strategy: validation

Validate before calling

if (ConfigProvider.getConfig().getOptionalValue("quarkus.mailer.dkim.selector", String.class).isPresent()
        && ConfigProvider.getConfig().getOptionalValue("quarkus.mailer.dkim.sdid", String.class).isEmpty()) {
    throw new IllegalStateException("dkim configured but quarkus.mailer.dkim.sdid is missing");
}

Try / catch

try {
    mailer.send(mail).await().indefinitely();
} catch (ConfigurationException e) {
    if (e.getMessage().contains("sdid")) {
        LOG.error("Set quarkus.mailer.dkim.sdid to your signing domain", e);
    }
    throw e;
}

Prevention

When it happens

Trigger: quarkus.mailer.dkim.sdid (or per-mailer quarkus.mailer.<name>.dkim.sdid) is absent while any other dkim.* property is set, triggering DKIM setup at mailer config build time.

Common situations: Configuring dkim.selector, dkim.private-key, etc. but forgetting sdid; YAML/properties nesting mistake putting sdid outside the dkim block; copying DKIM config between named mailers and dropping the sdid line.

Related errors


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