aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib/schedulers
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-04-23 09:32:53 +0200
committerChocobozzz <chocobozzz@cpy.re>2020-05-04 16:21:39 +0200
commit8dc8a34ee8428e7657414115d1c137592efa174d (patch)
treee9b5ef0d7446d1b7766eac18da5a759edc7a9040 /server/lib/schedulers
parent7fed637506043e4432cbebe041ada0625171cceb (diff)
downloadPeerTube-8dc8a34ee8428e7657414115d1c137592efa174d.tar.gz
PeerTube-8dc8a34ee8428e7657414115d1c137592efa174d.tar.zst
PeerTube-8dc8a34ee8428e7657414115d1c137592efa174d.zip
Avoir some circular dependencies
Diffstat (limited to 'server/lib/schedulers')
-rw-r--r--server/lib/schedulers/auto-follow-index-instances.ts2
-rw-r--r--server/lib/schedulers/update-videos-scheduler.ts2
-rw-r--r--server/lib/schedulers/videos-redundancy-scheduler.ts4
3 files changed, 4 insertions, 4 deletions
diff --git a/server/lib/schedulers/auto-follow-index-instances.ts b/server/lib/schedulers/auto-follow-index-instances.ts
index a1f5e4a91..e852c7fc6 100644
--- a/server/lib/schedulers/auto-follow-index-instances.ts
+++ b/server/lib/schedulers/auto-follow-index-instances.ts
@@ -6,7 +6,7 @@ import { chunk } from 'lodash'
6import { doRequest } from '@server/helpers/requests' 6import { doRequest } from '@server/helpers/requests'
7import { ActorFollowModel } from '@server/models/activitypub/actor-follow' 7import { ActorFollowModel } from '@server/models/activitypub/actor-follow'
8import { JobQueue } from '@server/lib/job-queue' 8import { JobQueue } from '@server/lib/job-queue'
9import { getServerActor } from '@server/helpers/utils' 9import { getServerActor } from '@server/models/application/application'
10 10
11export class AutoFollowIndexInstances extends AbstractScheduler { 11export class AutoFollowIndexInstances extends AbstractScheduler {
12 12
diff --git a/server/lib/schedulers/update-videos-scheduler.ts b/server/lib/schedulers/update-videos-scheduler.ts
index 956780a77..d32c1c068 100644
--- a/server/lib/schedulers/update-videos-scheduler.ts
+++ b/server/lib/schedulers/update-videos-scheduler.ts
@@ -2,7 +2,7 @@ import { logger } from '../../helpers/logger'
2import { AbstractScheduler } from './abstract-scheduler' 2import { AbstractScheduler } from './abstract-scheduler'
3import { ScheduleVideoUpdateModel } from '../../models/video/schedule-video-update' 3import { ScheduleVideoUpdateModel } from '../../models/video/schedule-video-update'
4import { retryTransactionWrapper } from '../../helpers/database-utils' 4import { retryTransactionWrapper } from '../../helpers/database-utils'
5import { federateVideoIfNeeded } from '../activitypub' 5import { federateVideoIfNeeded } from '../activitypub/videos'
6import { SCHEDULER_INTERVALS_MS } from '../../initializers/constants' 6import { SCHEDULER_INTERVALS_MS } from '../../initializers/constants'
7import { Notifier } from '../notifier' 7import { Notifier } from '../notifier'
8import { sequelizeTypescript } from '../../initializers/database' 8import { sequelizeTypescript } from '../../initializers/database'
diff --git a/server/lib/schedulers/videos-redundancy-scheduler.ts b/server/lib/schedulers/videos-redundancy-scheduler.ts
index e33a4133a..8da9d52b5 100644
--- a/server/lib/schedulers/videos-redundancy-scheduler.ts
+++ b/server/lib/schedulers/videos-redundancy-scheduler.ts
@@ -6,11 +6,10 @@ import { VideoRedundancyModel } from '../../models/redundancy/video-redundancy'
6import { downloadWebTorrentVideo, generateMagnetUri } from '../../helpers/webtorrent' 6import { downloadWebTorrentVideo, generateMagnetUri } from '../../helpers/webtorrent'
7import { join } from 'path' 7import { join } from 'path'
8import { move } from 'fs-extra' 8import { move } from 'fs-extra'
9import { getServerActor } from '../../helpers/utils'
10import { sendCreateCacheFile, sendUpdateCacheFile } from '../activitypub/send' 9import { sendCreateCacheFile, sendUpdateCacheFile } from '../activitypub/send'
11import { getVideoCacheFileActivityPubUrl, getVideoCacheStreamingPlaylistActivityPubUrl } from '../activitypub/url' 10import { getVideoCacheFileActivityPubUrl, getVideoCacheStreamingPlaylistActivityPubUrl } from '../activitypub/url'
12import { removeVideoRedundancy } from '../redundancy' 11import { removeVideoRedundancy } from '../redundancy'
13import { getOrCreateVideoAndAccountAndChannel } from '../activitypub' 12import { getOrCreateVideoAndAccountAndChannel } from '../activitypub/videos'
14import { downloadPlaylistSegments } from '../hls' 13import { downloadPlaylistSegments } from '../hls'
15import { CONFIG } from '../../initializers/config' 14import { CONFIG } from '../../initializers/config'
16import { 15import {
@@ -26,6 +25,7 @@ import {
26} from '@server/typings/models' 25} from '@server/typings/models'
27import { getVideoFilename } from '../video-paths' 26import { getVideoFilename } from '../video-paths'
28import { VideoModel } from '@server/models/video/video' 27import { VideoModel } from '@server/models/video/video'
28import { getServerActor } from '@server/models/application/application'
29 29
30type CandidateToDuplicate = { 30type CandidateToDuplicate = {
31 redundancy: VideosRedundancyStrategy 31 redundancy: VideosRedundancyStrategy