1
0
Fork 0
peertube/server/lib/schedulers/remove-old-jobs-scheduler.ts

20 lines
407 B
TypeScript
Raw Normal View History

import { JobQueue } from '../job-queue'
import { AbstractScheduler } from './abstract-scheduler'
export class RemoveOldJobsScheduler extends AbstractScheduler {
private static instance: AbstractScheduler
private constructor () {
super()
}
async execute () {
JobQueue.Instance.removeOldJobs()
}
static get Instance () {
return this.instance || (this.instance = new this())
}
}