Skip to content
This repository has been archived by the owner on Apr 14, 2023. It is now read-only.

fix: do not send GQL_STOP after GQL_COMPLETED is received #775

Merged
merged 5 commits into from
Aug 10, 2020
Merged

fix: do not send GQL_STOP after GQL_COMPLETED is received #775

merged 5 commits into from
Aug 10, 2020

Conversation

onhate
Copy link
Contributor

@onhate onhate commented Jun 30, 2020

fix #711

@onhate onhate marked this pull request as draft June 30, 2020 15:01
@onhate onhate marked this pull request as ready for review June 30, 2020 16:42
@onhate
Copy link
Contributor Author

onhate commented Jul 2, 2020

@abernix WDYT?

@onhate
Copy link
Contributor Author

onhate commented Jul 3, 2020

@trevorblades let me know your thoughts.

@onhate
Copy link
Contributor Author

onhate commented Jul 6, 2020

@hwillson @stubailo could you shed a light on here? who is the responsible for this repository?

@onhate
Copy link
Contributor Author

onhate commented Jul 6, 2020

I have publish a parallel version while that, if anyone want to get access to this fix/improvement feel free to use it

https://www.npmjs.com/package/@texelz/subscriptions-transport-ws/v/0.9.1-6.no-gql-stop

it just need a little hack if you are using WebSocketLink, because of this
https://github.com/apollographql/apollo-link/blob/master/packages/apollo-link-ws/src/webSocketLink.ts#L38

class WebSocketLink extends ApolloLink {
  constructor(private client: SubscriptionClient) {
    super();
  }

  request(operation: Operation) {
    return this.client.request(operation) as any;
  }
}

@onhate onhate closed this Jul 6, 2020
@onhate onhate reopened this Jul 6, 2020
Copy link
Member

@hwillson hwillson left a comment

Choose a reason for hiding this comment

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

Thanks very much for working on this @onhate - and sorry for the long delay in getting this merged!

@hwillson hwillson merged commit d200f44 into apollographql:master Aug 10, 2020
@fredli74
Copy link

This change causes server memory leaks. #805

I personally do not think it's a bad client fix, but the server does not handle it correctly.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GQL_STOP sent after "complete" from server
3 participants