fix: allow errors to propogate in integration sync to facilitate retries unless final attempt

This commit is contained in:
Scott Wilson
2024-09-27 17:02:20 -07:00
parent efa54e0c46
commit a44b3efeb7

View File

@@ -930,6 +930,11 @@ export const secretQueueFactory = ({
}
});
// re-throw error to re-run job unless final attempt, then log and send fail email
if (job.attemptsStarted !== job.opts.attempts) {
throw err;
}
await integrationDAL.updateById(integration.id, {
lastSyncJobId: job.id,
syncMessage: message,