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

Respond with 'Sec-WebSocket-Protocol' header on connect when requested #84

Merged
merged 1 commit into from
Jun 9, 2020

Conversation

lepilepi
Copy link
Contributor

@lepilepi lepilepi commented Jun 9, 2020

The subscription wasn't working with Playground because it requested with the Sec-WebSocket-Protocol: graphql-ws header and expected the same to be returned on connect.

With this error exactly:
Error during WebSocket handshake: Sent non-empty 'Sec-WebSocket-Protocol' header but no response was received

The proposed fix is to respond with that header when requested.
(Tested with both playground the the provided chat-example-app)

@lepilepi lepilepi marked this pull request as draft June 9, 2020 15:25
@michalkvasnicak
Copy link
Owner

Are you sure this actually works? Because it wasn't supported by AWS AG v2 and according to this thread it's still unsupported.

@lepilepi
Copy link
Contributor Author

lepilepi commented Jun 9, 2020

Are you sure this actually works? Because it wasn't supported by AWS AG v2 and according to this thread it's still unsupported.

Deployed on aws: it worked with both playground and that chat-example-app.

@lepilepi lepilepi marked this pull request as ready for review June 9, 2020 15:51
@michalkvasnicak
Copy link
Owner

Thank you very much @lepilepi.

@michalkvasnicak michalkvasnicak merged commit 85cdb7d into michalkvasnicak:master Jun 9, 2020
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

Successfully merging this pull request may close these issues.

2 participants