You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 17, 2024. It is now read-only.
(Forgive me if there is a better avenue for this question. The README does not indicate any place to ask for help.)
We had an event today where Sidekiq went down, but Clockwork kept pushing worker requests into Redis. When we restarted Sidekiq, multiple instances of my MxxWorker were queued up, and Sidekiq started running them concurrently, despite my having set sidekiq_options unique: :all in the class.
The worker takes no parameter, so these instances should not be unique. Why didn't Sidekiq discard the dupes. Am I misunderstanding how this is supposed to work?
Here is the relevant part of the class definition:
class MxxWorker
include Sidekiq::Worker
sidekiq_options unique: :all
def perform
MxxWorker.run(Rails.logger)
end
def self.run(logger = Logger.new(STDOUT))
# blah code
end
# more code
end
Thanks to anyone who can enlighten me. I'd be happy to write some documentation about this once I understand it.
The text was updated successfully, but these errors were encountered:
I have the same issue, when performing a long job and we deploy, sidekiq will give 8 seconds before killing the worker and push the job back to redis; when sidekiq starts up again it will enqueue two jobs despite the uniqueness
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
(Forgive me if there is a better avenue for this question. The README does not indicate any place to ask for help.)
We had an event today where Sidekiq went down, but Clockwork kept pushing worker requests into Redis. When we restarted Sidekiq, multiple instances of my MxxWorker were queued up, and Sidekiq started running them concurrently, despite my having set
sidekiq_options unique: :all
in the class.The worker takes no parameter, so these instances should not be unique. Why didn't Sidekiq discard the dupes. Am I misunderstanding how this is supposed to work?
Here is the relevant part of the class definition:
Thanks to anyone who can enlighten me. I'd be happy to write some documentation about this once I understand it.
The text was updated successfully, but these errors were encountered: