-
Notifications
You must be signed in to change notification settings - Fork 99
Description
When setting the WithKeeplive
WithKeepAlive(time.time)
an asynchronous routine is enabled during pings using the underlying websocket handler from https://github.com/coder/websocket. This underlying handler uses the web socket protocol https://datatracker.ietf.org/doc/html/rfc6455#section-11.8 which is not similar to the sub-protocols graphql-ws
/ subscriptions-transport-ws
Which is supported by this library.
Concretely I experienced that a Graphql Server (implemented with https://github.com/99designs/gqlgen did not understand the pings because of the protocol-confussion, thus leading a connection being dropped and reinitialized.
I do not know whether this is how most servers are implemented, but the protocol is set upon the 101 switch protocol request by the client and then the server choses an appropiate messageExchanger based on the protocol