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.