transport

package
v2.15.0 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2018 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package transport defines various transports that can be used with RemoteReporter to send spans out of process. Transport is responsible for serializing the spans into a specific format suitable for sending to the tracing backend. Examples may include Thrift over UDP, Thrift or JSON over HTTP, Thrift over Kafka, etc.

Implementations are NOT required to be thread-safe; the RemoteReporter is expected to only call methods on the Transport from the same go-routine.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPBasicAuthCredentials added in v2.7.0

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

HTTPBasicAuthCredentials stores credentials for HTTP basic auth.

type HTTPOption added in v2.7.0

type HTTPOption func(c *HTTPTransport)

HTTPOption sets a parameter for the HttpCollector

func HTTPBasicAuth added in v2.7.0

func HTTPBasicAuth(username string, password string) HTTPOption

HTTPBasicAuth sets the credentials required to perform HTTP basic auth

func HTTPBatchSize added in v2.7.0

func HTTPBatchSize(n int) HTTPOption

HTTPBatchSize sets the maximum batch size, after which a collect will be triggered. The default batch size is 100 spans.

func HTTPRoundTripper added in v2.15.0

func HTTPRoundTripper(transport http.RoundTripper) HTTPOption

HTTPRoundTripper configures the underlying Transport on the *http.Client that is used

func HTTPTimeout added in v2.7.0

func HTTPTimeout(duration time.Duration) HTTPOption

HTTPTimeout sets maximum timeout for http request.

type HTTPTransport added in v2.7.0

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

HTTPTransport implements Transport by forwarding spans to a http server.

func NewHTTPTransport added in v2.7.0

func NewHTTPTransport(url string, options ...HTTPOption) *HTTPTransport

NewHTTPTransport returns a new HTTP-backend transport. url should be an http url of the collector to handle POST request, typically something like:

http://hostname:14268/api/traces?format=jaeger.thrift

func (*HTTPTransport) Append added in v2.7.0

func (c *HTTPTransport) Append(span *jaeger.Span) (int, error)

Append implements Transport.

func (*HTTPTransport) Close added in v2.7.0

func (c *HTTPTransport) Close() error

Close implements Transport.

func (*HTTPTransport) Flush added in v2.7.0

func (c *HTTPTransport) Flush() (int, error)

Flush implements Transport.

Directories

Path Synopsis
Package zipkin provides various Transports that can be used with RemoteReporter for submitting traces to Zipkin backend.
Package zipkin provides various Transports that can be used with RemoteReporter for submitting traces to Zipkin backend.

Jump to

Keyboard shortcuts

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