Is there any API that allow me to edit the args before move it to retry set when it fails?

9 views
Skip to first unread message

liul85

unread,
May 9, 2016, 11:31:44 AM5/9/16
to Sidekiq
Hi guys,

I am new to sidekiq, ans just want to know is there any chance I can take to edit the failed job before sidekiq move it to retry queue?

I am doing a batch commit to solr with rsolr in sidekiq, every batch commit will add 100 documents to solr, and there may be some data format error in one document and this will cause solr raise exception when you try to add the documents to solr, as a result the total 100 documents will not be commited to solr at all, so what I want is when the job failed and before being moved to retry, I can divide the job to two jobs with each 50 documents and then to the retries.


thanks.

Mike Perham

unread,
May 9, 2016, 9:20:25 PM5/9/16
to sid...@googlegroups.com
Nope, there's no way to do that and Sidekiq explicitly takes measures to make it hard.  If you want to save the progress of a job in your app, you should store it as part of the app's data.  Otherwise you should create one job per document.

Mike

--
You received this message because you are subscribed to the Google Groups "Sidekiq" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sidekiq+u...@googlegroups.com.
To post to this group, send email to sid...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sidekiq/242ce5f9-4f30-4084-a19c-9117403a130f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Mike Perham – CEO, Contributed Systems
Smart, effective open source infrastructure for your apps.
Reply all
Reply to author
Forward
0 new messages