blob: 080093563e5772e61739f3268aad4bb027548058 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
import { VideoConstant } from '../videos'
import { RunnerJobPayload } from './runner-job-payload.model'
import { RunnerJobPrivatePayload } from './runner-job-private-payload.model'
import { RunnerJobState } from './runner-job-state.model'
import { RunnerJobType } from './runner-job-type.type'
export interface RunnerJob <T extends RunnerJobPayload = RunnerJobPayload> {
uuid: string
type: RunnerJobType
state: VideoConstant<RunnerJobState>
payload: T
failures: number
error: string | null
progress: number
priority: number
startedAt: Date | string
createdAt: Date | string
updatedAt: Date | string
finishedAt: Date | string
parent?: {
type: RunnerJobType
state: VideoConstant<RunnerJobState>
uuid: string
}
// If associated to a runner
runner?: {
id: number
name: string
description: string
}
}
// eslint-disable-next-line max-len
export interface RunnerJobAdmin <T extends RunnerJobPayload = RunnerJobPayload, U extends RunnerJobPrivatePayload = RunnerJobPrivatePayload> extends RunnerJob<T> {
privatePayload: U
}
|