Skip to content
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

Allow customizing retry logic for http requests #974

Merged
merged 2 commits into from
Dec 11, 2022
Merged

Conversation

quinnj
Copy link
Member

@quinnj quinnj commented Dec 9, 2022

Supersedes #877

Allow user to pass `retry_delays` with a custom `ExponentialBackoff` object.
Allow user to pass `retry_check` that is a function of the form:
`check(s, ex, req, resp) -> Bool` which will be called if the default
retry logic doesn't allow retrying.
@codecov-commenter
Copy link

codecov-commenter commented Dec 9, 2022

Codecov Report

Merging #974 (ef84fa4) into master (16383f2) will decrease coverage by 0.12%.
The diff coverage is 72.41%.

@@            Coverage Diff             @@
##           master     #974      +/-   ##
==========================================
- Coverage   79.97%   79.84%   -0.13%     
==========================================
  Files          36       36              
  Lines        2961     2967       +6     
==========================================
+ Hits         2368     2369       +1     
- Misses        593      598       +5     
Impacted Files Coverage Δ
src/HTTP.jl 73.33% <ø> (ø)
src/clientlayers/ExceptionRequest.jl 100.00% <ø> (ø)
src/clientlayers/RetryRequest.jl 69.04% <25.00%> (-7.70%) ⬇️
src/clientlayers/MessageRequest.jl 90.00% <85.71%> (-10.00%) ⬇️
src/Messages.jl 85.96% <88.88%> (-0.51%) ⬇️
src/clientlayers/StreamRequest.jl 97.14% <100.00%> (ø)
src/Streams.jl 94.88% <0.00%> (-1.14%) ⬇️
src/WebSockets.jl 87.82% <0.00%> (+0.36%) ⬆️
src/clientlayers/ConnectionRequest.jl 80.24% <0.00%> (+1.23%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@quinnj quinnj merged commit 02ba345 into master Dec 11, 2022
@quinnj quinnj deleted the jq-custom-retry branch December 11, 2022 00:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants