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