When deploying apollo-server-lambda as per the readme, the url used by the playground is wrong when using the API gateway execute-api domain.
I believe this is caused by the change made in #1527.
This example payload for this type of event includes a url of https://70ixmpl4fl.execute-api.ca-central-1.amazonaws.com/Prod/, with event.requestContext.path of /Prod/ (the stage name). The event.path is /. Clearly in this case using event.path would be incorrect.
When using an API gateway with a custom domain, the values for event.requestContext.path and event.path are identical.
I'd be happy to submit a PR to fix this, but it would be good to understand why this was changed in the first place first as I don't want to break anything.
When deploying
apollo-server-lambdaas per the readme, the url used by the playground is wrong when using the API gateway execute-api domain.I believe this is caused by the change made in #1527.
This example payload for this type of event includes a url of
https://70ixmpl4fl.execute-api.ca-central-1.amazonaws.com/Prod/, withevent.requestContext.pathof/Prod/(the stage name). Theevent.pathis/. Clearly in this case usingevent.pathwould be incorrect.When using an API gateway with a custom domain, the values for
event.requestContext.pathandevent.pathare identical.I'd be happy to submit a PR to fix this, but it would be good to understand why this was changed in the first place first as I don't want to break anything.