Keepalive config should be independent of TLS

pull/3482/head
Ben Langfeld 8 years ago
parent 588f7a8443
commit 3b22ecd53b

@ -157,6 +157,8 @@ func start() {
logger.Fatalf("Could not create server TLS configuration: %v", err) logger.Fatalf("Could not create server TLS configuration: %v", err)
} }
opts = append(opts, grpc.Creds(credentials.NewTLS(cfg))) opts = append(opts, grpc.Creds(credentials.NewTLS(cfg)))
}
opts = append(opts, grpc.KeepaliveParams(keepalive.ServerParameters{ opts = append(opts, grpc.KeepaliveParams(keepalive.ServerParameters{
MaxConnectionIdle: 10 * time.Minute, MaxConnectionIdle: 10 * time.Minute,
// If needed, we can configure the max connection age // If needed, we can configure the max connection age
@ -164,7 +166,6 @@ func start() {
opts = append(opts, grpc.KeepaliveEnforcementPolicy(keepalive.EnforcementPolicy{ opts = append(opts, grpc.KeepaliveEnforcementPolicy(keepalive.EnforcementPolicy{
MinTime: time.Duration(20) * time.Second, // For compatibility with the client keepalive.ClientParameters MinTime: time.Duration(20) * time.Second, // For compatibility with the client keepalive.ClientParameters
})) }))
}
rootServer = tiller.NewServer(opts...) rootServer = tiller.NewServer(opts...)

Loading…
Cancel
Save