gRPC KeepAlive

keep-alive settings

Here are some good settings for an initial configuration of a SpringBoot FactCast client/server setup in case you ran into gRPC related client server communication troubles.

  • Sending keep-alive HTTP/2 PINGs on the connection is useful in case you are running on infrastructure that doesn’t support configurable idle timeouts, and therefore closes connections.

  • The proposed values are defining a scenario where the client sends keep-alive HTTP/2 PINGs every 300s and the server accepts this behavior without sending GO_AWAY ENHANCE_YOUR_CALM to the client. Please adapt to your specific needs.

Client side

PropertyDescriptionRecommendedDefault
spring.grpc.client.channels.factstore.enable-keep-aliveConfigures whether keepAlive should be enabled.truefalse
spring.grpc.client.channels.factstore.keep-alive-timeThe default delay before sending keepAlives. Please note that shorter intervals increase the network burden for the server.30060
spring.grpc.client.channels.factstore.keep-alive-without-callsConfigures whether keepAlive will be performed when there are no outstanding RPCs on a connection.truefalse

Further details can be found here : org.springframework.grpc.autoconfigure.client.GrpcClientProperties.

Server side

PropertyDescriptionRecommendedDefault
spring.grpc.server.keep-alive.permit-without-callsConfigures whether clients are allowed to send keep-alive HTTP/2 PINGs even if there are no outstanding RPCs on the connection.truefalse
spring.grpc.server.keep-alive.permit-timeSpecifies the most aggressive keep-alive time in seconds clients are permitted to configure.100300

Further details can be found here : org.springframework.grpc.autoconfigure.server.GrpcServerProperties.

Last modified February 23, 2026 : #4262: update docs (29fec8714)