go-autorest: github.com/Azure/go-autorest/tracing Index | Files | Directories

package tracing

import "github.com/Azure/go-autorest/tracing"

Index

Package Files

tracing.go

func EndSpan Uses

func EndSpan(ctx context.Context, httpStatusCode int, err error)

EndSpan ends a previously started span stored in the context. Has no effect if a Tracer has not been registered.

func IsEnabled Uses

func IsEnabled() bool

IsEnabled returns true if a Tracer has been registered.

func NewTransport Uses

func NewTransport(base *http.Transport) http.RoundTripper

NewTransport creates a new instrumenting http.RoundTripper for the registered Tracer. If no Tracer has been registered it returns nil.

func Register Uses

func Register(t Tracer)

Register will register the provided Tracer. Pass nil to unregister a Tracer.

func StartSpan Uses

func StartSpan(ctx context.Context, name string) context.Context

StartSpan starts a trace span with the specified name, associating it with the provided context. Has no effect if a Tracer has not been registered.

type Tracer Uses

type Tracer interface {
    NewTransport(base *http.Transport) http.RoundTripper
    StartSpan(ctx context.Context, name string) context.Context
    EndSpan(ctx context.Context, httpStatusCode int, err error)
}

Tracer represents an HTTP tracing facility.

Directories

PathSynopsis
opencensus

Package tracing imports 2 packages (graph) and is imported by 1028 packages. Updated 2019-08-15. Refresh now. Tools for package owners.