Versions in this module Expand all Collapse all v1 v1.5.2 Sep 27, 2023 Changes in this version + var ClientField = ctxlog.NewFields("span.kind", "client") + var DefaultDurationToField = DurationToTimeMillisField + var ServerField = ctxlog.NewFields("span.kind", "server") + var SystemField = ctxlog.NewFields("system", "grpc") + func DefaultClientCodeToLevel(code codes.Code) logger.Level + func DefaultCodeToLevel(code codes.Code) logger.Level + func DefaultMessageProducer(ctx context.Context, msg string, level logger.Level, code codes.Code, ...) + func DurationToDurationField(duration time.Duration) map[string]interface + func DurationToTimeMillisField(duration time.Duration) ctxlog.Fields + func StreamClientInterceptor(opts ...Option) grpc.StreamClientInterceptor + func StreamServerInterceptor(opts ...Option) grpc.StreamServerInterceptor + func UnaryClientInterceptor(opts ...Option) grpc.UnaryClientInterceptor + func UnaryServerInterceptor(opts ...Option) grpc.UnaryServerInterceptor + type CodeToLevel func(code codes.Code) logger.Level + type DurationToField func(duration time.Duration) ctxlog.Fields + type MessageProducer func(ctx context.Context, msg string, level logger.Level, code codes.Code, ...) + type Option func(*options) + func WithCodes(f grpc_logging.ErrorToCode) Option + func WithDecider(f grpc_logging.Decider) Option + func WithDurationField(f DurationToField) Option + func WithLevels(f CodeToLevel) Option + func WithMessageProducer(f MessageProducer) Option + func WithTimestampFormat(format string) Option