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

[Feature] ObjectBody needs a response_body equivalent when using the http feature #687

Open
1 task done
robmv opened this issue Dec 30, 2024 · 0 comments
Open
1 task done

Comments

@robmv
Copy link

robmv commented Dec 30, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Description

Currently ObjectBody.responseBody() is a more CPU efficient way to stream the body of an R2 object, but it uses the "legacy?" ResponseBody structure and no alternative exist for when the http feature is enabled that uses http-body traits.

Maybe exposing a ReadableStream from ObjectBody with some kind of into_inner() that can be used with worker::Body::new() constructor could be the new API.

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

No branches or pull requests

1 participant