GraphQL Websockets fails to send payload after 8 messages

53 Views Asked by At

I'm having an issue with my graphql websocket handler. Our setup is using Springboot, Redis with Jedis for the server and ws-graphql with urql for the client. When attempting to form a subscription from the client the server sends an ack, and then after subscribing sends a payload. The client then continues receiving all payloads until 8 have been sent, at which point the server simply stops responding. Here is an example in the chrome web tools:

Chrome web tools error

The subscription I have setup in spring is as follows:

@SubscriptionMapping
    fun listenForCollaborators(authentication: Authentication, @Argument viewId: String): Publisher<ViewCollaborators> {
        val userId = userService.getUserFromPrincipal(authentication.principal).id

        updateCollaboratorsList(viewId, userId)

        val initialCollaborators = operations.opsForList().range(viewId, 0, -1)
        val mono = ViewCollaborators(viewId, initialCollaborators ?: emptyList())
        return Mono.just(mono)
    }

We've tried multiple different publisher types (Flux & Mono), and tried to dig through the documentation to find where the limit of 8 could be coming from to no avail.

Thanks

0

There are 0 best solutions below