import { Knex } from 'knex';
import { Logger } from 'winston';
import { PluginTaskScheduler, TaskDescriptor, TaskInvocationDefinition, TaskRunner, TaskScheduleDefinition } from './types';
/**
 * Implements the actual task management.
 */
export declare class PluginTaskSchedulerImpl implements PluginTaskScheduler {
    private readonly databaseFactory;
    private readonly logger;
    private readonly localTasksById;
    private readonly allScheduledTasks;
    private readonly counter;
    private readonly duration;
    constructor(databaseFactory: () => Promise<Knex>, logger: Logger);
    triggerTask(id: string): Promise<void>;
    scheduleTask(task: TaskScheduleDefinition & TaskInvocationDefinition): Promise<void>;
    createScheduledTaskRunner(schedule: TaskScheduleDefinition): TaskRunner;
    getScheduledTasks(): Promise<TaskDescriptor[]>;
    private wrapInMetrics;
}
export declare function parseDuration(frequency: TaskScheduleDefinition['frequency']): string;
