othttp

package
v0.0.0-...-69f936c Latest Latest
Warning

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

Go to latest
Published: Oct 12, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTracedHTTPClient

func NewTracedHTTPClient() *http.Client

NewTracedHTTPClient returns a new traced http.Client

func ServerMiddleware

func ServerMiddleware(h http.Handler) http.Handler

ServerMiddleware wraps a given http.Handler with OpenTracing instrumentation

Types

type TracedTransport

type TracedTransport struct {
	*http.Transport
}

TracedTransport is a traced HTTP transport that captures http call spans

func (*TracedTransport) RoundTrip

func (t *TracedTransport) RoundTrip(r *http.Request) (resp *http.Response, err error)

RoundTrip satisfies the RoundTripper interface, wraps the sub Transport and captures a span of the HTTP request.

Jump to

Keyboard shortcuts

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