pmemcommon

package
v0.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 6, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Errorf

func Errorf(ctx context.Context, format string, args ...interface{})

Errorf does the same as Infof for error messages, except that it ignores the current log level.

func Infof

func Infof(level glog.Level, ctx context.Context, format string, args ...interface{})

Infof logs with glog.V(level).Infof() and in addition, always adds a log message to the current tracing span if the context has one. This ensures that spans which get recorded (not all do) have the full information.

func InitTracer

func InitTracer(component string) (closer io.Closer, err error)

InitTracer initializes the global OpenTracing tracer, using Jaeger and the provided name for the current process. Must be called at the start of main(). The result is a function which should be called at the end of main() to clean up.

func LogGRPCClient

func LogGRPCClient(ctx context.Context, method string, req, reply interface{}, cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error

LogGRPCClient does the same as LogGRPCServer, only on the client side.

func LogGRPCServer

func LogGRPCServer(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)

LogGRPCServer logs the server-side call information via glog.

Warning: at log levels >= 5 the recorded information includes all parameters, which potentially contains sensitive information like the secrets.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL