-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sidekiq/util has been removed in 6.5.0 #21
Conversation
I think this broke our sidekiq when I deployed it. Hold on
|
6849637
to
22d4704
Compare
@@ -1,12 +1,18 @@ | |||
require "get_process_mem" | |||
require "sidekiq" | |||
require "sidekiq/util" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since worker_killer is a server middleware, you should include the new Module as noted here: https://github.com/mperham/sidekiq/blob/main/docs/middleware.md#updated-api You can then access the identity with |
@mperham Thanks. Updated the PR and added a test for finding the process from the processset for the 'identity' to ensure it doesn't fail again |
@@ -125,6 +131,10 @@ def sidekiq_process | |||
end || raise("No sidekiq worker with identity #{identity} found") | |||
end | |||
|
|||
def identity | |||
config[:identity] || config["identity"] | |||
end unless method_defined?(:identity) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
include Sidekiq::Util will have defined this. Else we define it and call the interface added by Sidekiq::ServerMiddleware
"queues" => %w[low medium high] | ||
}] | ||
end | ||
it "finds the process by identity" do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since this is a critical failure point, I figured a test would be a good idea
Why not just have a new version that only supports 6.5+? Let people use an old version of swk if they want to run an old version of Sidekiq. |
re "Why not just have a new version that only supports 6.5+? Let people use an old version of swk if they want to run an old version of Sidekiq." I'm not a maintainer of this. 👍 on that, though |
Still getting failures. Gotta look deeper. maybe something about the heartbeat? maybe something redis-specific which is why it's not showing up in tests? looks like somehow Processor is getting a nil I'm trying to reproduce it locally and get more context my local gem changes, fwiw sidekiq 6.4.2 -> 6.5.0 |
Scout APM’s gem breaks Sidekiq 6.5 with this error, see their issue tracker. |
@mperham Thanks for that. I thought I might have noticed it on local server shutdown but hadn't reproduced it yet |
It's a bad idea to add breaking changes to minor update, isn't ? |
Sidekiq::Processor is not a public API nor is sidekiq/util. I take compatibility very seriously for documented, public APIs, deprecate things and document them in major version release notes. |
so why so many gems were broken? (rhetorical question) :) |
What needs to be done to merge this and release a new gem version, please? |
I'm running this fork in prod. I am not a maintainer can't merge or release |
@ccyrille Any chance for a new release? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @bf4, thanks a lot for your contribution and sorry for the late reply! LGTM! I will release a new version of the gem today (cc @slayer @themilkman).
Please note that we are not using sidekiq-worker-killer
internally at Klaxit anymore. Maybe it would be a good to add external maintainers. Is it something you could be interested in ?
@ccyrille Sure, I'm up to add some bandwidth in both github and rubygems, if you're up for it. Is really just in maintenance mode anyhow. |
see sidekiq/sidekiq@v6.4.2...v6.5.0
Follows sidekiq/sidekiq#5340