aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/videos
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-05-03 11:38:07 +0200
committerChocobozzz <me@florianbigard.com>2022-05-03 14:49:15 +0200
commit26e3e98ff0e222a9fb9226938ac6902af77921bd (patch)
tree73d1c6f2524e380862d3365f12043fc319d40841 /shared/models/videos
parent86c5229b4d726202378ef46854383bcafca22310 (diff)
downloadPeerTube-26e3e98ff0e222a9fb9226938ac6902af77921bd.tar.gz
PeerTube-26e3e98ff0e222a9fb9226938ac6902af77921bd.tar.zst
PeerTube-26e3e98ff0e222a9fb9226938ac6902af77921bd.zip
Support live session in server
Diffstat (limited to 'shared/models/videos')
-rw-r--r--shared/models/videos/live/index.ts2
-rw-r--r--shared/models/videos/live/live-video-error.enum.ts7
-rw-r--r--shared/models/videos/live/live-video-session.model.ts16
3 files changed, 25 insertions, 0 deletions
diff --git a/shared/models/videos/live/index.ts b/shared/models/videos/live/index.ts
index 68f32092a..07b59fe2c 100644
--- a/shared/models/videos/live/index.ts
+++ b/shared/models/videos/live/index.ts
@@ -1,6 +1,8 @@
1export * from './live-video-create.model' 1export * from './live-video-create.model'
2export * from './live-video-error.enum'
2export * from './live-video-event-payload.model' 3export * from './live-video-event-payload.model'
3export * from './live-video-event.type' 4export * from './live-video-event.type'
4export * from './live-video-latency-mode.enum' 5export * from './live-video-latency-mode.enum'
6export * from './live-video-session.model'
5export * from './live-video-update.model' 7export * from './live-video-update.model'
6export * from './live-video.model' 8export * from './live-video.model'
diff --git a/shared/models/videos/live/live-video-error.enum.ts b/shared/models/videos/live/live-video-error.enum.ts
new file mode 100644
index 000000000..3a8e4afa0
--- /dev/null
+++ b/shared/models/videos/live/live-video-error.enum.ts
@@ -0,0 +1,7 @@
1export const enum LiveVideoError {
2 BAD_SOCKET_HEALTH = 1,
3 DURATION_EXCEEDED = 2,
4 QUOTA_EXCEEDED = 3,
5 FFMPEG_ERROR = 4,
6 BLACKLISTED = 5
7}
diff --git a/shared/models/videos/live/live-video-session.model.ts b/shared/models/videos/live/live-video-session.model.ts
new file mode 100644
index 000000000..7ff6afbe5
--- /dev/null
+++ b/shared/models/videos/live/live-video-session.model.ts
@@ -0,0 +1,16 @@
1import { LiveVideoError } from './live-video-error.enum'
2
3export interface LiveVideoSession {
4 id: number
5
6 startDate: string
7 endDate: string
8
9 error: LiveVideoError
10
11 replayVideo: {
12 id: number
13 uuid: string
14 shortUUID: string
15 }
16}