Skip to content

Websocket server doesn't have a keepAlive #2429

Open
@tinleym

Description

@tinleym

Summary

Reading the websocket server implementation here, I noticed that there are no keepAlive processes.

https://github.com/graphile/crystal/blob/4fe66c21bc4280315b2ae1ce5d39c7a933bb259f/grafast/grafserv/src/servers/node/index.ts

Possible Solution

Instead of directly using makeServer, graphql-ws offers a higher level useServer function, which wraps makeServer with keepAlive processes via a single parameter. If nothing else, its source could be a useful guide:

https://the-guild.dev/graphql/ws/docs/use/ws/functions/useServer

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    🐭 Shrew

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions