Involved Source Filescomponent.go Package grpclog defines logging for grpc.
In the default logger, severity level can be set by environment variable
GRPC_GO_LOG_SEVERITY_LEVEL, verbosity level can be set by
GRPC_GO_LOG_VERBOSITY_LEVEL.logger.gologgerv2.go
Package-Level Type Names (total 4, in which 3 are exported)
/* sort exporteds by: | */
DepthLoggerV2 logs at a specified call frame. If a LoggerV2 also implements
DepthLoggerV2, the below functions will be called with the appropriate stack
depth set for trivial functions the logger may ignore.
# Experimental
Notice: This type is EXPERIMENTAL and may be changed or removed in a
later release. Error logs to ERROR log. Arguments are handled in the manner of fmt.Print. ErrorDepth logs to ERROR log at the specified depth. Arguments are handled in the manner of fmt.Println. Errorf logs to ERROR log. Arguments are handled in the manner of fmt.Printf. Errorln logs to ERROR log. Arguments are handled in the manner of fmt.Println. Fatal logs to ERROR log. Arguments are handled in the manner of fmt.Print.
gRPC ensures that all Fatal logs will exit with os.Exit(1).
Implementations may also call os.Exit() with a non-zero exit code. FatalDepth logs to FATAL log at the specified depth. Arguments are handled in the manner of fmt.Println. Fatalf logs to ERROR log. Arguments are handled in the manner of fmt.Printf.
gRPC ensures that all Fatal logs will exit with os.Exit(1).
Implementations may also call os.Exit() with a non-zero exit code. Fatalln logs to ERROR log. Arguments are handled in the manner of fmt.Println.
gRPC ensures that all Fatal logs will exit with os.Exit(1).
Implementations may also call os.Exit() with a non-zero exit code. Info logs to INFO log. Arguments are handled in the manner of fmt.Print. InfoDepth logs to INFO log at the specified depth. Arguments are handled in the manner of fmt.Println. Infof logs to INFO log. Arguments are handled in the manner of fmt.Printf. Infoln logs to INFO log. Arguments are handled in the manner of fmt.Println. V reports whether verbosity level l is at least the requested verbose level. Warning logs to WARNING log. Arguments are handled in the manner of fmt.Print. WarningDepth logs to WARNING log at the specified depth. Arguments are handled in the manner of fmt.Println. Warningf logs to WARNING log. Arguments are handled in the manner of fmt.Printf. Warningln logs to WARNING log. Arguments are handled in the manner of fmt.Println.
google.golang.org/grpc/grpclog/internal.DepthLoggerV2(interface)
*componentData
DepthLoggerV2 : LoggerV2
DepthLoggerV2 : google.golang.org/grpc/grpclog/internal.DepthLoggerV2
DepthLoggerV2 : google.golang.org/grpc/grpclog/internal.LoggerV2
DepthLoggerV2 : go.uber.org/goleak.TestingT
DepthLoggerV2 : go.uber.org/mock/gomock.TestReporter
func Component(componentName string) DepthLoggerV2
func google.golang.org/grpc/internal/channelz.AddTraceEvent(l DepthLoggerV2, e channelz.Entity, depth int, desc *channelz.TraceEvent)
func google.golang.org/grpc/internal/channelz.Error(l DepthLoggerV2, e channelz.Entity, args ...any)
func google.golang.org/grpc/internal/channelz.Errorf(l DepthLoggerV2, e channelz.Entity, format string, args ...any)
func google.golang.org/grpc/internal/channelz.Info(l DepthLoggerV2, e channelz.Entity, args ...any)
func google.golang.org/grpc/internal/channelz.Infof(l DepthLoggerV2, e channelz.Entity, format string, args ...any)
func google.golang.org/grpc/internal/channelz.Warning(l DepthLoggerV2, e channelz.Entity, args ...any)
func google.golang.org/grpc/internal/channelz.Warningf(l DepthLoggerV2, e channelz.Entity, format string, args ...any)
func google.golang.org/grpc/internal/grpclog.NewPrefixLogger(logger DepthLoggerV2, prefix string) *grpclog.PrefixLogger
var google.golang.org/grpc.logger
var google.golang.org/grpc/balancer.logger
var google.golang.org/grpc/balancer/base.logger
var google.golang.org/grpc/balancer/pickfirst.logger
var google.golang.org/grpc/balancer/pickfirst/pickfirstleaf.logger
var google.golang.org/grpc/balancer/roundrobin.logger
var google.golang.org/grpc/connectivity.logger
var google.golang.org/grpc/credentials.logger
var google.golang.org/grpc/experimental/stats.logger
var google.golang.org/grpc/health.logger
var google.golang.org/grpc/internal/binarylog.grpclogLogger
var google.golang.org/grpc/internal/channelz.logger
var google.golang.org/grpc/internal/credentials.logger
var google.golang.org/grpc/internal/resolver/delegatingresolver.logger
var google.golang.org/grpc/internal/resolver/dns.logger
var google.golang.org/grpc/internal/serviceconfig.logger
var google.golang.org/grpc/internal/syscall.logger
var google.golang.org/grpc/internal/transport.logger
LoggerV2 does underlying logging work for grpclog. Error logs to ERROR log. Arguments are handled in the manner of fmt.Print. Errorf logs to ERROR log. Arguments are handled in the manner of fmt.Printf. Errorln logs to ERROR log. Arguments are handled in the manner of fmt.Println. Fatal logs to ERROR log. Arguments are handled in the manner of fmt.Print.
gRPC ensures that all Fatal logs will exit with os.Exit(1).
Implementations may also call os.Exit() with a non-zero exit code. Fatalf logs to ERROR log. Arguments are handled in the manner of fmt.Printf.
gRPC ensures that all Fatal logs will exit with os.Exit(1).
Implementations may also call os.Exit() with a non-zero exit code. Fatalln logs to ERROR log. Arguments are handled in the manner of fmt.Println.
gRPC ensures that all Fatal logs will exit with os.Exit(1).
Implementations may also call os.Exit() with a non-zero exit code. Info logs to INFO log. Arguments are handled in the manner of fmt.Print. Infof logs to INFO log. Arguments are handled in the manner of fmt.Printf. Infoln logs to INFO log. Arguments are handled in the manner of fmt.Println. V reports whether verbosity level l is at least the requested verbose level. Warning logs to WARNING log. Arguments are handled in the manner of fmt.Print. Warningf logs to WARNING log. Arguments are handled in the manner of fmt.Printf. Warningln logs to WARNING log. Arguments are handled in the manner of fmt.Println.DepthLoggerV2(interface)
google.golang.org/grpc/grpclog/internal.DepthLoggerV2(interface)
google.golang.org/grpc/grpclog/internal.LoggerV2(interface)
*google.golang.org/grpc/grpclog/internal.LoggerWrapper
*componentData
*google.golang.org/grpc/grpclog/internal.loggerT
LoggerV2 : google.golang.org/grpc/grpclog/internal.LoggerV2
LoggerV2 : go.uber.org/goleak.TestingT
LoggerV2 : go.uber.org/mock/gomock.TestReporter
func NewLoggerV2(infoW, warningW, errorW io.Writer) LoggerV2
func NewLoggerV2WithVerbosity(infoW, warningW, errorW io.Writer, v int) LoggerV2
func newLoggerV2() LoggerV2
func SetLoggerV2(l LoggerV2)
Package-Level Functions (total 27, in which 25 are exported)
Component creates a new component and returns it for logging. If a component
with the name already exists, nothing will be created and it will be
returned. SetLoggerV2 will panic if it is called with a logger created by
Component.
Error logs to the ERROR log.
ErrorDepth logs to the ERROR log at the specified depth.
# Experimental
Notice: This API is EXPERIMENTAL and may be changed or removed in a
later release.
Errorf logs to the ERROR log. Arguments are handled in the manner of fmt.Printf.
Errorln logs to the ERROR log. Arguments are handled in the manner of fmt.Println.
Fatal logs to the FATAL log. Arguments are handled in the manner of fmt.Print.
It calls os.Exit() with exit code 1.
FatalDepth logs to the FATAL log at the specified depth.
# Experimental
Notice: This API is EXPERIMENTAL and may be changed or removed in a
later release.
Fatalf logs to the FATAL log. Arguments are handled in the manner of fmt.Printf.
It calls os.Exit() with exit code 1.
Fatalln logs to the FATAL log. Arguments are handled in the manner of fmt.Println.
It calls os.Exit() with exit code 1.
Info logs to the INFO log.
InfoDepth logs to the INFO log at the specified depth.
# Experimental
Notice: This API is EXPERIMENTAL and may be changed or removed in a
later release.
Infof logs to the INFO log. Arguments are handled in the manner of fmt.Printf.
Infoln logs to the INFO log. Arguments are handled in the manner of fmt.Println.
NewLoggerV2 creates a loggerV2 with the provided writers.
Fatal logs will be written to errorW, warningW, infoW, followed by exit(1).
Error logs will be written to errorW, warningW and infoW.
Warning logs will be written to warningW and infoW.
Info logs will be written to infoW.
NewLoggerV2WithVerbosity creates a loggerV2 with the provided writers and
verbosity level.
Print prints to the logger. Arguments are handled in the manner of fmt.Print.
Deprecated: use Info.
Printf prints to the logger. Arguments are handled in the manner of fmt.Printf.
Deprecated: use Infof.
Println prints to the logger. Arguments are handled in the manner of fmt.Println.
Deprecated: use Infoln.
SetLogger sets the logger that is used in grpc. Call only from
init() functions.
Deprecated: use SetLoggerV2.
SetLoggerV2 sets logger that is used in grpc to a V2 logger.
Not mutex-protected, should be called before any gRPC functions.
V reports whether verbosity level l is at least the requested verbose level.
Warning logs to the WARNING log.
WarningDepth logs to the WARNING log at the specified depth.
# Experimental
Notice: This API is EXPERIMENTAL and may be changed or removed in a
later release.
Warningf logs to the WARNING log. Arguments are handled in the manner of fmt.Printf.
Warningln logs to the WARNING log. Arguments are handled in the manner of fmt.Println.