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

HTTP client: Support compression (Content-Encoding: gzip) #377

Open
clue opened this issue Jul 12, 2020 · 4 comments
Open

HTTP client: Support compression (Content-Encoding: gzip) #377

clue opened this issue Jul 12, 2020 · 4 comments

Comments

@clue
Copy link
Member

clue commented Jul 12, 2020

This library should support requesting compressed responses and automatically decompress using the Accept-Encoding request header and Content-Encoding response header.

This should be an opt-in feature.

Implementing this for buffered requests shouldn't be too hard. This should make sure to also respect the withResponseBuffer() setting.

Implementing this for streaming requests is doable, see also https://github.com/clue/reactphp-zlib.

We welcome contributions, reach out if you want to support this project 👍

@maxgalbu
Copy link

maxgalbu commented Dec 14, 2022

For buffered responses, it's as easy as doing gzdecode/gzdeflate(), or does it need async solutions?

@WyriHaximus
Copy link
Member

IIRC you can decode streams in chunks, and either me or @clue might have the package for it lying around AFAIK

@maxgalbu
Copy link

maxgalbu commented Feb 23, 2023

How will this library change with reactphp v3? Will changes to this library still be accepted?

@SimonFrings
Copy link
Member

How will this library change with reactphp v3

@maxgalbu You can read about our rough plans for each project and ReactPHP in whole in our discussion: https://github.com/orgs/reactphp/discussions/481
We will also release a more detailed roadmap for each repository in the next couple of weeks, to show the upcoming features and necessary steps towards the new major release, stay tuned.

Will changes to this library still be accepted?

While ReactPHP v3 will be the way forward, we are also committed to continue supporting the current v1 for a certain amount of time, if you have any ideas or want to contribute to the project, we're happy to take a look. In short: Yes, changes will be accepted 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants