UNPKG

655 BTypeScriptView Raw
1import * as Rx from 'rxjs';
2import { Command } from '../command';
3import { Logger } from '../logger';
4import { FlowController } from './flow-controller';
5/**
6 * Restarts commands that fail up to a defined number of times.
7 */
8export declare class RestartProcess implements FlowController {
9 private readonly logger;
10 private readonly scheduler?;
11 readonly delay: number;
12 readonly tries: number;
13 constructor({ delay, tries, logger, scheduler, }: {
14 delay?: number;
15 tries?: number;
16 logger: Logger;
17 scheduler?: Rx.SchedulerLike;
18 });
19 handle(commands: Command[]): {
20 commands: Command[];
21 };
22}