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

ALB Event Handler Not Decoding Query String Parameters on GETs #7742

Open
yhakbar opened this issue Sep 27, 2023 · 0 comments
Open

ALB Event Handler Not Decoding Query String Parameters on GETs #7742

yhakbar opened this issue Sep 27, 2023 · 0 comments

Comments

@yhakbar
Copy link

yhakbar commented Sep 27, 2023

Issue Description

While trying to switch from an API Gateway fronted Lambda function running Apollo to an ALB, we encountered 400 errors when users made GET requests to the server.

The exception is thrown here:
https://github.com/apollographql/apollo-server/blob/main/packages/server/src/runHttpQuery.ts#L62

and I think it basically boils down to the fact that this:
https://github.com/apollographql/apollo-server/blob/main/packages/server/src/runHttpQuery.ts#L44

is not:

return decodeURIComponent(values[0]);

Is this user error because we have not URL decoded the query string parameter before sending the request down, or is Apollo server expected to handle this for us? It doesn't seem like this was required when running with the API Gateway handler.

Link to Reproduction

I can't do this, as it requires provisioning AWS resources.

Reproduction Steps

Create an ALB and send a GET request with a query string parameter that is URL encoded JSON content.

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