Setu-TS
    Preparing search index...

    Interface KubernetesDiscoveryOptions

    The 'kubernetes' arm — EndpointSlices read from the API server.

    0.2.0

    interface KubernetesDiscoveryOptions {
        apiServer?: string;
        cacheTtlMs?: number;
        ejection?: false | EjectionOptions;
        http?: IDiscoveryHttp;
        namespace: string;
        portName?: string;
        provider: "kubernetes";
        secure?: boolean;
        selfRegistration?: SelfRegistration;
        strategy?: LoadBalanceStrategy;
        token?: string;
    }

    Hierarchy

    • CommonDiscoveryOptions
      • KubernetesDiscoveryOptions
    Index
    apiServer?: string

    API server base URL. Defaults to the in-cluster https://$KUBERNETES_SERVICE_HOST:$KUBERNETES_SERVICE_PORT.

    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.

    ejection?: false | EjectionOptions

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

    Overrides the default fetch-backed HTTP seam.

    namespace: string

    Namespace the services live in.

    portName?: string

    Selects the ports[] entry by name when a service exposes several.

    provider: "kubernetes"

    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.

    token?: string

    Bearer token, used verbatim.

    Omit it in-cluster and the provider reads the projected service-account token instead, re-reading it periodically because Kubernetes rotates it.