Skip to content

Commit

Permalink
Revert "Revert "[common-go] Adjust log level and ping keepalive inter…
Browse files Browse the repository at this point in the history
…val""

This reverts commit 7141a5c.
  • Loading branch information
csweichel authored Oct 12, 2021
1 parent 3139b81 commit 7b6e806
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions components/common-go/grpc/grpc.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ func DefaultClientOptions() []grpc.DialOption {
Backoff: bfConf,
}),
grpc.WithKeepaliveParams(keepalive.ClientParameters{
Time: 5 * time.Second,
Time: 10 * time.Second,
Timeout: time.Second,
PermitWithoutStream: true,
}),
Expand All @@ -85,7 +85,7 @@ func ServerOptionsWithInterceptors(stream []grpc.StreamServerInterceptor, unary
return []grpc.ServerOption{
// terminate the connection if the client pings more than once every 2 seconds
grpc.KeepaliveEnforcementPolicy(keepalive.EnforcementPolicy{
MinTime: 2 * time.Second,
MinTime: 10 * time.Second,
PermitWithoutStream: true,
}),
grpc.MaxRecvMsgSize(maxMsgSize),
Expand All @@ -101,7 +101,7 @@ func ServerOptionsWithInterceptors(stream []grpc.StreamServerInterceptor, unary

func SetupLogging() {
grpclog.SetLoggerV2(grpclog.NewLoggerV2(
log.WithField("component", "grpc").WriterLevel(logrus.InfoLevel),
log.WithField("component", "grpc").WriterLevel(logrus.DebugLevel),
log.WithField("component", "grpc").WriterLevel(logrus.WarnLevel),
log.WithField("component", "grpc").WriterLevel(logrus.ErrorLevel),
))
Expand Down

0 comments on commit 7b6e806

Please sign in to comment.