Skip to content

Multipart responses #2591

Answered by seanmonstar
ghost asked this question in Q&A
Discussion options

You must be logged in to vote

hyper doesn't do anything special to implement range requests. You could use a server framework that provides support, like warp. Or you can just handle them yourself with hyper. That'd mean:

  • Sending an Accept-Range: bytes header in responses that support it.
  • Parsing a Range header in requests.
  • Using those parsed indices, return a body with just the parts requested.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by seanmonstar
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant
Converted from issue

This discussion was converted from issue #2589 on July 06, 2021 17:48.