| 94 | } |
| 95 | |
| 96 | interface AdvancedSettings { |
| 97 | /** |
| 98 | * Key expiration time for job locks |
| 99 | */ |
| 100 | lockDuration?: number | undefined; |
| 101 | |
| 102 | /** |
| 103 | * Interval in milliseconds on which to acquire the job lock. |
| 104 | */ |
| 105 | lockRenewTime?: number | undefined; |
| 106 | |
| 107 | /** |
| 108 | * How often check for stalled jobs (use 0 for never checking) |
| 109 | */ |
| 110 | stalledInterval?: number | undefined; |
| 111 | |
| 112 | /** |
| 113 | * Max amount of times a stalled job will be re-processed |
| 114 | */ |
| 115 | maxStalledCount?: number | undefined; |
| 116 | |
| 117 | /** |
| 118 | * Poll interval for delayed jobs and added jobs |
| 119 | */ |
| 120 | guardInterval?: number | undefined; |
| 121 | |
| 122 | /** |
| 123 | * Delay before processing next job in case of internal error |
| 124 | */ |
| 125 | retryProcessDelay?: number | undefined; |
| 126 | |
| 127 | /** |
| 128 | * Define a custom backoff strategy |
| 129 | */ |
| 130 | backoffStrategies?: |
| 131 | | { |
| 132 | [key: string]: ( |
| 133 | attemptsMade: number, |
| 134 | err: Error, |
| 135 | strategyOptions?: any |
| 136 | ) => number; |
| 137 | } |
| 138 | | undefined; |
| 139 | |
| 140 | /** |
| 141 | * A timeout for when the queue is in `drained` state (empty waiting for jobs). |
| 142 | * It is used when calling `queue.getNextJob()`, which will pass it to `.brpoplpush` on the Redis client. |
| 143 | */ |
| 144 | drainDelay?: number | undefined; |
| 145 | } |
| 146 | |
| 147 | type DoneCallback = (error?: Error | null, value?: any) => void; |
| 148 |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…