exthttp

package
v0.0.0-...-3eb76e5 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type InstrumentationMiddleware

type InstrumentationMiddleware interface {
	// WrapHandler wraps the given HTTP handler for instrumentation.
	WrapHandler(handlerName string, handler http.Handler) http.HandlerFunc
}

InstrumentationMiddleware holds necessary metrics to instrument an http.Server and provides necessary behaviors.

func NewInstrumentationMiddleware

func NewInstrumentationMiddleware(reg prometheus.Registerer, buckets []float64, tp *tracing.Provider) InstrumentationMiddleware

NewInstrumentationMiddleware provides default InstrumentationMiddleware. Passing nil as buckets uses the default buckets.

func NewNopInstrumentationMiddleware

func NewNopInstrumentationMiddleware() InstrumentationMiddleware

NewNopInstrumentationMiddleware provides a InstrumentationMiddleware which does nothing.

type InstrumentationTripperware

type InstrumentationTripperware interface {
	WrapRoundTripper(targetName string, next http.RoundTripper) http.RoundTripper
}

InstrumentationTripperware holds necessary metrics to instrument an http.RoundTripper and provides necessary behaviors.

func NewInstrumentationTripperware

func NewInstrumentationTripperware(reg prometheus.Registerer, buckets []float64, tp *tracing.Provider) InstrumentationTripperware

NewInstrumentationTripperware provides default InstrumentationTripperware. Passing nil as buckets uses the default buckets. TODO(bwplotka): Add optional args.

func NewNopInstrumentationTripperware

func NewNopInstrumentationTripperware() InstrumentationTripperware

NewNopInstrumentationTripperware provides a InstrumentationTripperware which does nothing.

Jump to

Keyboard shortcuts

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