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

Take the content-encoding header into account when parsing a query #879

Closed
SadiinsoSnowfall opened this issue Mar 25, 2022 · 2 comments · May be fixed by #995
Closed

Take the content-encoding header into account when parsing a query #879

SadiinsoSnowfall opened this issue Mar 25, 2022 · 2 comments · May be fixed by #995
Labels
enhancement New feature or request Stale

Comments

@SadiinsoSnowfall
Copy link
Contributor

SadiinsoSnowfall commented Mar 25, 2022

Currently, async-graphql reads the content-type header when parsing a GQL query to know if the query is encoded in JSON or CBOR.
However, it doesn't read the content-encoding header, which might indicate that the query was compressed.

Async-graphql should read the content-encoding header and decompress the payload if needed before parsing the query according to the content-type header. I think it would be sufficient for a first implementation of this feature to only handle gzip compression; and this could be guarded behind a crate feature to mirror what was done with CBOR decoding.

Request compression is a niche use case but it can substantially reduce the volume of data sent to the GQL server. This is why I think it could be important to support this.

@github-actions
Copy link

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@github-actions github-actions bot added the Stale label Aug 29, 2022
@github-actions
Copy link

github-actions bot commented Sep 4, 2022

This issue was closed because it has been stalled for 5 days with no activity.

@github-actions github-actions bot closed this as completed Sep 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Stale
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant