Skip to content

WebSocket keepalive PING not emitted for all idle concurrent sessions #1447

@KelltonTechSolutions

Description

@KelltonTechSolutions

I am seeing inconsistent server-side WebSocket keepalive behavior with Spring GraphQL over WebFlux.

The application is configured with:

spring.graphql.websocket.path=/graphql
spring.graphql.websocket.keep-alive=15s
spring.netty.idle-timeout=0
In a scenario with two concurrent GraphQL WebSocket clients using the graphql-transport-ws protocol, one connection receives periodic server PING frames while another concurrently active connection does not.

I reviewed the keepalive support added in commit 80ef960 and expected each idle WebSocket connection to receive server PING frames independently.

This is on my local environment, when i deploy the solution to POD. SLB, closes the connection after XX duration for session B.

Question

Is this behavior expected because Spring GraphQL suppresses keepalive when a session has had recent encoded output, or should each concurrently idle WebSocket session receive its own PING frames independently?

Metadata

Metadata

Assignees

Labels

in: webIssues related to web handlingstatus: backportedAn issue that has been backported to maintenance branchestype: bugA general bug

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions