diff --git a/src/KubernetesClient/Kubernetes.ConfigInit.cs b/src/KubernetesClient/Kubernetes.ConfigInit.cs index 6394213..e3213fb 100644 --- a/src/KubernetesClient/Kubernetes.ConfigInit.cs +++ b/src/KubernetesClient/Kubernetes.ConfigInit.cs @@ -192,7 +192,12 @@ namespace k8s // // Should remove after better solution - var sh = new SocketsHttpHandler(); + var sh = new SocketsHttpHandler + { + KeepAlivePingPolicy = HttpKeepAlivePingPolicy.WithActiveRequests, + KeepAlivePingDelay = TimeSpan.FromMinutes(3), + KeepAlivePingTimeout = TimeSpan.FromSeconds(30), + }; sh.ConnectCallback = async (context, token) => { var socket = new Socket(SocketType.Stream, ProtocolType.Tcp)