diff options
Diffstat (limited to 'server/lib/job-queue/job-queue.ts')
-rw-r--r-- | server/lib/job-queue/job-queue.ts | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/server/lib/job-queue/job-queue.ts b/server/lib/job-queue/job-queue.ts index 5862e178f..ba9cbe0d9 100644 --- a/server/lib/job-queue/job-queue.ts +++ b/server/lib/job-queue/job-queue.ts | |||
@@ -88,7 +88,6 @@ class JobQueue { | |||
88 | 88 | ||
89 | queue.on('error', err => { | 89 | queue.on('error', err => { |
90 | logger.error('Error in job queue %s.', handlerName, { err }) | 90 | logger.error('Error in job queue %s.', handlerName, { err }) |
91 | process.exit(-1) | ||
92 | }) | 91 | }) |
93 | 92 | ||
94 | this.queues[handlerName] = queue | 93 | this.queues[handlerName] = queue |
@@ -166,10 +165,10 @@ class JobQueue { | |||
166 | return total | 165 | return total |
167 | } | 166 | } |
168 | 167 | ||
169 | removeOldJobs () { | 168 | async removeOldJobs () { |
170 | for (const key of Object.keys(this.queues)) { | 169 | for (const key of Object.keys(this.queues)) { |
171 | const queue = this.queues[key] | 170 | const queue = this.queues[key] |
172 | queue.clean(JOB_COMPLETED_LIFETIME, 'completed') | 171 | await queue.clean(JOB_COMPLETED_LIFETIME, 'completed') |
173 | } | 172 | } |
174 | } | 173 | } |
175 | 174 | ||