Sidekiq schedule same worker to queue when done

二次信任 提交于 2019-12-01 08:05:16

Strange. I do the same thing except use self.class instead of BotWorker and it works. I don't have any arguments for my perform method though.

You might want to wrap your method in a begin/rescue/ensure block and move the re-queuing into the ensure block.

If User.find fails to find a user, it's going to raise an error which Sidekiq will catch and should move your job into the Retry queue. Probably not what you want.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!