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

Incompatibility with GraphQL clients for subscriptions #123

Open
S4G4R opened this issue Mar 8, 2022 · 4 comments
Open

Incompatibility with GraphQL clients for subscriptions #123

S4G4R opened this issue Mar 8, 2022 · 4 comments

Comments

@S4G4R
Copy link

S4G4R commented Mar 8, 2022

Most GraphQL client libraries have moved on from using the subscriptions-transport-ws (which is no longer maintained) implementation in favour of graphql-ws for subscriptions.

This causes compatibility issues, as in our case, we are trying to use the ApolloGraphQL client and lacinia-pedestal server and are unable to do so.

To enhance compatibility with client libraries, it would be great to move to the newer graphql-ws implementation.

@S4G4R S4G4R changed the title Migrate protocol? Migrate subscription protocol? Mar 8, 2022
@S4G4R S4G4R changed the title Migrate subscription protocol? Incompatibility with GraphQL clients for subscriptions Mar 18, 2022
@hlship
Copy link
Member

hlship commented Apr 15, 2022

Was this fixed by #124 ?

@atsfour
Copy link
Contributor

atsfour commented Apr 17, 2022

@hlship

Probably not.

To fix this issue, the lacinia-pedestal server must support the graphql-transport-ws protocol.

specified by: https://github.com/enisdenjo/graphql-ws/blob/master/PROTOCOL.md

Currently, lacinia-pedestal supports the older graphql-ws protocol.

specified by: https://github.com/apollographql/subscriptions-transport-ws/blob/master/PROTOCOL.md

(The naming of the library and protocol does not match, which is confusing)

I suspect It is needed to change the implementation of subscriptions / connection-loop to handle requests for new protocols as well. Also, for backward compatibility, I think it is better to keep the support of the old protocol.

https://github.com/walmartlabs/lacinia-pedestal/blob/master/src/com/walmartlabs/lacinia/pedestal/subscriptions.clj#L105

@hlship
Copy link
Member

hlship commented Aug 19, 2022

So I think this was fixed by #126, right?

@hlship hlship added this to the 1.2 milestone Aug 19, 2022
@hlship
Copy link
Member

hlship commented Aug 19, 2022

Oh, right, #126 isn't merged yet.

@hlship hlship removed this from the 1.2 milestone Jun 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging a pull request may close this issue.

3 participants