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

Change: Change websocket lib to graphql-ws #20282

Merged

Conversation

Tainan404
Copy link
Member

@Tainan404 Tainan404 commented May 16, 2024

What does this PR do?

It changes to a better supported library graphql-ws

One of the main reasons of this decision is that our old library was deprecated
image

https://github.com/apollographql/subscriptions-transport-ws

@Tainan404 Tainan404 marked this pull request as draft May 16, 2024 19:06
@antobinary antobinary modified the milestone: Release 3.0 May 16, 2024
@gustavotrott
Copy link
Collaborator

Tainan404#30

After conducting some tests, I found that migrating to graphql-transport-ws is as simple as renaming some messages types:

start -> subscribe
data -> next
stop -> complete
keep_alive -> ping / pong (the middleware simply forwards these)

Aside from these changes, the overall structure remains the same.

More details at:
https://github.com/enisdenjo/graphql-ws/blob/master/PROTOCOL.md

@Tainan404 Tainan404 marked this pull request as ready for review May 21, 2024 18:51
Copy link

This pull request has conflicts ☹
Please resolve those so we can review the pull request.
Thanks.

@@ -1,12 +1,12 @@
import {
ApolloClient, ApolloProvider, InMemoryCache, NormalizedCacheObject, ApolloLink,
} from '@apollo/client';
import { WebSocketLink } from '@apollo/client/link/ws';
import { SubscriptionClient } from 'subscriptions-transport-ws';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be removed from package.json?

Copy link

sonarcloud bot commented May 22, 2024

Quality Gate Failed Quality Gate failed

Failed conditions
6.9% Duplication on New Code (required ≤ 3%)
C Reliability Rating on New Code (required ≥ A)

See analysis details on SonarCloud

Catch issues before they fail your Quality Gate with our IDE extension SonarLint

Copy link

Automated tests Summary

All the CI tests have passed!

@TiagoJacobs TiagoJacobs merged commit 1aab2f5 into bigbluebutton:v3.0.x-release May 22, 2024
26 of 27 checks passed
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.

None yet

4 participants