Repository navigation
Increase redlock redis timeout, backport CI changes - #14
Merged
Merged
Conversation
This makes the tests work on ruby 3.4. No runtime gems have been updated yet. Removed usage of internal Sidekiq API in the test to hopefully make updates simpler.
`.lock` yields the lock/lock information, if it is false the lock was not acquired. Moving the mocks removes the reliance on internal API of redlock, updating it should surface breakage if they changed the API or behaviour.
Their default is 0.1 seconds, since we started deploying servers in different regions this started to become a problem. Sidekiq does not recommend having a high latency but it still works, we on the other hand failed as soon as the ping between the two servers got larger than 100ms. https://github.com/leandromoreira/redlock-rb/tree/1.3.2#redlock-configuration
misku
reviewed
Oct 8, 2026
dsander
force-pushed
the
feature/increase-redlock-redis-timeout
branch
from
October 8, 2026 12:46
26d7f6b to
f2af7c1
Compare
Before we fixed the call we never actually validated that we got the lock from redlock, our `reschedule_all` call should be able to finish within 500ms, but if the ping to redis is larger we have less and less time, potentially blocking the startup of others by up to 5 seconds should not be an issue.
dsander
force-pushed
the
feature/increase-redlock-redis-timeout
branch
from
October 8, 2026 12:47
f2af7c1 to
0587c7a
Compare
misku
approved these changes
Oct 8, 2026
misku
left a comment
Member
There was a problem hiding this comment.
Thank you! I think this is the correct way of approving a PR on github 👴
Member
Author
Thanks! :dawey: /merge |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The first two commits are cherry picked from
master, done in the Sidekiq 8 update, it adds CI and fixes the tests on Ruby 3.4. This targets 0.2 (for Sidekiq 6)Increase redlock redis timeout to 1 second
Their default is 0.1 seconds, since we started deploying servers in
different regions this started to become a problem. Sidekiq does not
recommend having a high latency but it still works, we on the other hand
failed as soon as the ping between the two servers got larger than
100ms.
https://github.com/leandromoreira/redlock-rb/tree/1.3.2#redlock-configuration