trace

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FromIncomingContext

func FromIncomingContext(ctx context.Context) (context.Context, opentracing.StartSpanOption)

rpc: FromIncomingContext

func FromOutgoingContext

func FromOutgoingContext(ctx context.Context) (context.Context, metadata.MD)

rpc: FromOutgoingContext

func HeaderExtractor

func HeaderExtractor(ctx context.Context, carrier map[string][]string) (context.Context, opentracing.StartSpanOption)

HTTP: HeaderExtractor

func MetadataInjector

func MetadataInjector(ctx context.Context, md metadata.MD) error

rpc: MetadataInjector

func SetGlobalTracer

func SetGlobalTracer(tracer opentracing.Tracer)

func SpanFromContext

func SpanFromContext(ctx context.Context) opentracing.Span

func TraceID

func TraceID(ctx context.Context) string

Types

type Metadata

type Metadata struct {
	// contains filtered or unexported fields
}

func New

func New() *Metadata

func (*Metadata) ForeachKey

func (md *Metadata) ForeachKey(handler func(key, val string) error) error

func (*Metadata) Set

func (md *Metadata) Set(key, val string)

type NullStartSpanOption

type NullStartSpanOption struct{}

func (NullStartSpanOption) Apply

func (sso NullStartSpanOption) Apply(options *opentracing.StartSpanOptions)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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