@camunda8/orchestration-cluster-api
    Preparing search index...

    Interface JobWorker

    interface JobWorker {
        get activeJobs(): number;
        get name(): string;
        get stopped(): boolean;
        start(): void;
        stop(): void;
        stopGracefully(
            opts?: { checkIntervalMs?: number; waitUpToMs?: number },
        ): Promise<{ remainingJobs: number; timedOut: boolean }>;
    }
    Index

    Accessors

    Methods

    • Gracefully stop the worker: prevent new polls, allow any in-flight activation to finish without cancellation, and wait for currently active jobs to drain (be acknowledged) up to waitUpToMs. If timeout is reached, falls back to hard stop logic (cancels activation if still pending).

      Parameters

      • Optionalopts: { checkIntervalMs?: number; waitUpToMs?: number }

      Returns Promise<{ remainingJobs: number; timedOut: boolean }>