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.
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
Timeout on body #303
Timeout on body #303
Changes from 6 commits
9b422a6
99b4f2d
c06d70e
ffa590b
f9466ed
83cacf9
969c3cb
d3e5df7
7753978
aa7b313
992827a
3182815
ae0cd93
f476dca
28dea10
b6a0b31
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
Taking a big step back, this could live in
http_body
crate if there was a standard interface for sleep futures.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.
Yeah, I think we do want to add a timeout body in http-body-utils, that said we can start with that code in here. I think this is the path I am going with for the retry stuff as well.
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.
Might want to consider using
futures_core::ready!
in the above poll so that the match becomes a match overOption<Result<...>>
instead ofPoll<Option<Result<...>>>
. Its basically the try macro but for poll fn. https://docs.rs/futures-core/latest/futures_core/macro.ready.html