trace

package
v1.2.9 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Tracer opentracing.Tracer

Tracer ...

Functions

func Close

func Close()

Close ...

func NewContext added in v1.2.8

func NewContext(ctx context.Context, t Trace) context.Context

NewContext new a trace context. NOTE: This method is not thread safe.

func StartSpan

func StartSpan(operationName string) opentracing.Span

StartSpan ...

Types

type Config

type Config struct {
	ServiceName string
	ZipkinHost  string
	HostName    string
}

Config is...

type GinTrace added in v1.2.8

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

GinTrace ..

func (*GinTrace) TraceID added in v1.2.8

func (g *GinTrace) TraceID() string

TraceID ..

type Trace added in v1.2.8

type Trace interface {
	// return current trace id.
	TraceID() string
}

Trace return current trace id.

func FromContext added in v1.2.8

func FromContext(ctx context.Context) (t Trace, ok bool)

FromContext returns the trace bound to the context, if any.

func NewGinTrace added in v1.2.8

func NewGinTrace(s string) Trace

NewGinTrace ..

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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