Skip to content

Duplicate subscribe/complete operations, a possible bug? #422

Answered by constantind
constantind asked this question in Q&A
Discussion options

You must be logged in to vote

Hi, @enisdenjo

Sorry didnt have time to write one, but here is another example query followed by subscription:

The lock could only help to serialize it but unfairly and creates more problems including deadlock. The way i solve this problem is the following, since clearly the query type subscribe sends complete and the subscription ones request the client to send complete, effectively makes each connection calls init -> subscribe -> complete, the client ids cannot be trusted, the protocol says regardless of the type but not regardless of operation AST. Which should it execute query or subscription when they work differently? Looks like apollo 3 executes both but returns to client only the…

Replies: 2 comments 12 replies

Comment options

You must be logged in to vote
6 replies
@constantind
Comment options

@enisdenjo
Comment options

@constantind
Comment options

@enisdenjo
Comment options

@constantind
Comment options

Comment options

You must be logged in to vote
6 replies
@enisdenjo
Comment options

@constantind
Comment options

@enisdenjo
Comment options

@constantind
Comment options

Answer selected by constantind
@enisdenjo
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants