Setu-TS
    Preparing search index...

    Interface ADnsDiscoveryOptions

    The 'dns' arm in address mode — A/AAAA records carry no port.

    interface ADnsDiscoveryOptions {
        cacheTtlMs?: number;
        domainTemplate?: string;
        ejection?: false | EjectionOptions;
        mode: "a";
        port: number;
        provider: "dns";
        secure?: boolean;
        selfRegistration?: SelfRegistration;
        strategy?: LoadBalanceStrategy;
        watchIntervalMs?: number;
    }

    Hierarchy

    • DnsDiscoveryCommon
      • ADnsDiscoveryOptions
    Index
    cacheTtlMs?: number

    Milliseconds a resolved instance list is served from cache.

    0 disables caching so every resolve hits the backend. A watched service invalidates its own entry on every change, so this is a safety net rather than the primary freshness mechanism.

    domainTemplate?: string

    {service} is replaced with the requested name.

    ejection?: false | EjectionOptions

    Outlier-ejection tuning, or false to disable ejection entirely.

    mode: "a"

    Query A/AAAA records.

    port: number

    Port every resolved address is reached on.

    Mandatory in this mode and absent from the 'srv' arm: DNS address records carry no port, and defaulting to 80 would silently point traffic at the wrong place.

    provider: "dns"

    Discriminant.

    secure?: boolean

    Whether resolved instances speak TLS.

    selfRegistration?: SelfRegistration

    Advertise this instance to the backend (Consul only).

    Default selection strategy; PickOptions.strategy overrides it per call.

    watchIntervalMs?: number

    Milliseconds between watch() polls — DNS has no push channel.