-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Retry with backoff on cluster connection failures #2358
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
Merged
Merged
Changes from 9 commits
Commits
Show all changes
46 commits
Select commit
Hold shift + click to select a range
6e2f312
Split JedisClusterCommand into multiple methods
5a4fdbd
Drop redundant null check
fc3728a
Bump JDK version to 1.8
cdf56b2
Replace ConnectionGetters with lambdas
d99ef7b
Retrigger CI
8978ca5
Add backoff to Redis connections
85fa21c
Add unit tests for backoff logic
f8d09c2
Add retries logging
9c7ef1d
Always use the user requested timeout
9bce8eb
Remedy review feedback
67a062a
Consider connection exceptions and disregard random nodes
sazzad16 7e4abac
Revert "Consider connection exceptions and disregard random nodes"
eabf10b
Add another backoff test case
3223404
consider connection exceptions and disregard random nodes
sazzad16 fd17343
reset redirection
sazzad16 bf56639
Fix test failure
walles c7ae6b5
Merge pull request #3 from sazzad16/backoff-walles
569afe7
Merge branch 'master' into j/backoff
walles 1638603
Apply suggestions from code review
68e8fdc
update documentation
sazzad16 c665dc1
Improve a comment
d9f2596
Update src/main/java/redis/clients/jedis/DefaultJedisSocketFactory.java
a23d602
Add change from another branch
6dd86db
Merge branch 'master' into j/backoff
walles fed69b0
Merge remote-tracking branch 'origin/master' into j/backoff
791180c
Move JedisClusterCommandTest out of commands package
sazzad16 4bf345b
Use JedisClusterOperationException
sazzad16 62a619e
Reduce sleep time, especially when few attempts left
sazzad16 f1c307d
Update src/main/java/redis/clients/jedis/JedisClusterCommand.java
sazzad16 8a9e0a8
Merge remote-tracking branch 'origin/master' into j/backoff
25c63a4
Merge branch 'master' into j/backoff
sazzad16 9b6242f
merge fix
sazzad16 73d74d3
Merge branch 'master' into j/backoff
gkorland d14174d
merge fix
sazzad16 af5d1f7
Merge remote-tracking branch 'redis/master' into j/backoff
sazzad16 ddd4038
Merge branch 'master' into j/backoff
sazzad16 7aa0b74
Merge branch 'master' into j/backoff
sazzad16 0ef36d3
Use maxAttempts
sazzad16 25303b7
format import
sazzad16 9e3fbcc
Re-add missing codes due to merge
sazzad16 882dd49
avoid NPE while zero max attempts
sazzad16 7430b9b
Remove zero attempts test
sazzad16 9eb8d58
More cluster constructors and customizability
sazzad16 27bce50
Use maxTotalRetriesDuration everywhere
sazzad16 b900a87
Merge remote-tracking branch 'redis/master' into j/backoff
sazzad16 4501b0d
more missing maxTotalRetriesDuration after merge
sazzad16 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
448 changes: 228 additions & 220 deletions
448
src/main/java/redis/clients/jedis/BinaryJedisCluster.java
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
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
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.