Complete the code to add a delay of 5000 milliseconds to the job.
this.queue.add('sendEmail', data, { delay: [1] });
The delay option expects the delay time in milliseconds. 5000 means 5 seconds delay before the job runs.
Complete the code to set the job to retry 3 times on failure.
this.queue.add('processData', data, { attempts: [1] });
The attempts option sets how many times the job will retry if it fails. Setting it to 3 means it will try up to 3 times.
Fix the error in setting the job priority to high (1 is highest).
this.queue.add('generateReport', data, { priority: [1] });
In NestJS job queues, lower numbers mean higher priority. 1 is the highest priority, so use 1.
Fill both blanks to add a job with 2 attempts and 3 seconds delay.
this.queue.add('cleanup', data, { attempts: [1], delay: [2] });
Set attempts to 2 for two retries, and delay to 3000 for 3 seconds delay (3000 milliseconds).
Fill all three blanks to add a job with high priority (1), 4 attempts, and 1 second delay.
this.queue.add('syncData', data, { priority: [1], attempts: [2], delay: [3] });
Priority 1 is highest, attempts 4 means 4 retries, and delay 1000 means 1 second delay.