Documentation
¶
Index ¶
- func CurrentSpan() opentracing.Span
- func Execute(op string, r *http.Request, client *http.Client) (*http.Response, error)
- func NewPropagatingRoundTripper(rt http.RoundTripper) http.RoundTripper
- func TraceChild(op string, fn func(span opentracing.Span) error) (err error)
- func TraceOrCreate(op string, fn func(span opentracing.Span) error) (err error)
- func WithSpan(span opentracing.Span, fn func())
- func WithSpanPropagation(client *http.Client) *http.Client
- type Middleware
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CurrentSpan ¶
func CurrentSpan() opentracing.Span
Returns the current span, or nil, if no span is currently set in local storage.
func NewPropagatingRoundTripper ¶ added in v1.4.3
func NewPropagatingRoundTripper(rt http.RoundTripper) http.RoundTripper
func TraceChild ¶
func TraceChild(op string, fn func(span opentracing.Span) error) (err error)
Runs an operation and traces it with the given name. This will create a new child span if some span is currently active.
func TraceOrCreate ¶
func TraceOrCreate(op string, fn func(span opentracing.Span) error) (err error)
Runs an operation and traces it with the given name. This will create a new span if no span is currently active.
func WithSpan ¶
func WithSpan(span opentracing.Span, fn func())
Runs the given function with the provided span set in local storage for the duration of function call. This method will not call 'Finish()' on the span
Types ¶
Click to show internal directories.
Click to hide internal directories.