SimonErm/react-native-job-queue

Retry Failed Job?

myckhel opened this issue · 4 comments

Question

Is it possible to retry failed job?

Yes you can pass attempts to the job options. https://simonerm.github.io/react-native-job-queue/docs/classes/queue#addjob
The attempts configure the number of retries.

Yes you can pass attempts to the job options. https://simonerm.github.io/react-native-job-queue/docs/classes/queue#addjob
The attempts configure the number of retries.

I meant manually retrying a particular job without letting it retry automatically.

That's not possible this way, but you could set the attempts to 0 and use the workers onFailure callback to add a new job with the same payload, which should lead to the same behaviour.

Okay.
Nice