mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-04 18:29:27 +02:00
Send views in a dedicated queue
This commit is contained in:
parent
3396e65345
commit
f27b7a750f
6 changed files with 24 additions and 5 deletions
|
@ -43,6 +43,7 @@ import { processVideosViewsStats } from './handlers/video-views-stats'
|
|||
|
||||
type CreateJobArgument =
|
||||
{ type: 'activitypub-http-broadcast', payload: ActivitypubHttpBroadcastPayload } |
|
||||
{ type: 'activitypub-http-broadcast-parallel', payload: ActivitypubHttpBroadcastPayload } |
|
||||
{ type: 'activitypub-http-unicast', payload: ActivitypubHttpUnicastPayload } |
|
||||
{ type: 'activitypub-http-fetcher', payload: ActivitypubHttpFetcherPayload } |
|
||||
{ type: 'activitypub-http-cleaner', payload: {} } |
|
||||
|
@ -68,6 +69,7 @@ export type CreateJobOptions = {
|
|||
|
||||
const handlers: { [id in JobType]: (job: Job) => Promise<any> } = {
|
||||
'activitypub-http-broadcast': processActivityPubHttpBroadcast,
|
||||
'activitypub-http-broadcast-parallel': processActivityPubHttpBroadcast,
|
||||
'activitypub-http-unicast': processActivityPubHttpUnicast,
|
||||
'activitypub-http-fetcher': processActivityPubHttpFetcher,
|
||||
'activitypub-cleaner': processActivityPubCleaner,
|
||||
|
@ -89,6 +91,7 @@ const handlers: { [id in JobType]: (job: Job) => Promise<any> } = {
|
|||
const jobTypes: JobType[] = [
|
||||
'activitypub-follow',
|
||||
'activitypub-http-broadcast',
|
||||
'activitypub-http-broadcast-parallel',
|
||||
'activitypub-http-fetcher',
|
||||
'activitypub-http-unicast',
|
||||
'activitypub-cleaner',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue