import { OnModuleDestroy, BeforeApplicationShutdown } from '@nestjs/common';
export interface PollOptions {
    baseDelayMs?: number;
    maxDelayMs?: number;
    timeoutPerIterationMs?: number;
    jitter?: boolean;
}
type ProcessNextFn = (queueName: string) => Promise<unknown>;
export declare class PollerService implements OnModuleDestroy, BeforeApplicationShutdown {
    private readonly logger;
    private readonly pollers;
    start(queueName: string, processNext: ProcessNextFn, options?: PollOptions): void;
    stop(queueName: string): void;
    stopAll(): void;
    onModuleDestroy(): Promise<void>;
    beforeApplicationShutdown(): Promise<void>;
    private poll;
    private schedule;
    private computeWait;
    private withTimeout;
    private errorToString;
}
export {};
//# sourceMappingURL=poller.service.d.ts.map