mirror of
https://github.com/whyour/qinglong.git
synced 2026-09-22 02:27:44 +08:00
feat(ql3): establish 3.0 incubation baseline
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
import type { ExecutionStopKind, ExecutorType } from '../domain/execution';
|
||||
|
||||
export const MAX_PRIMARY_CANCELLATION_BATCH_SIZE = 64;
|
||||
|
||||
export interface PrimaryCancellationCursor {
|
||||
requestedAtMs: number;
|
||||
runId: string;
|
||||
}
|
||||
|
||||
export interface PrimaryCancellationAttemptReference {
|
||||
attemptId: string;
|
||||
executorType: ExecutorType;
|
||||
executorHandle?: string;
|
||||
pid?: number;
|
||||
}
|
||||
|
||||
export interface PrimaryCancellationCandidate {
|
||||
runId: string;
|
||||
requestedAtMs: number;
|
||||
reason: ExecutionStopKind;
|
||||
attempts: readonly PrimaryCancellationAttemptReference[];
|
||||
}
|
||||
|
||||
export interface PrimaryCancellationPage {
|
||||
candidates: readonly PrimaryCancellationCandidate[];
|
||||
truncated: boolean;
|
||||
unsafeAttemptOverflow: boolean;
|
||||
nextCursor?: PrimaryCancellationCursor;
|
||||
}
|
||||
|
||||
export interface PrimaryCancellationSource {
|
||||
listCandidates(options?: {
|
||||
cursor?: PrimaryCancellationCursor;
|
||||
limit?: number;
|
||||
}): Promise<PrimaryCancellationPage>;
|
||||
}
|
||||
Reference in New Issue
Block a user