Documentation ¶
Index ¶
- Constants
- func HasBasicAuth(auth string) (string, bool)
- func Init(ctx context.Context, serviceName, endpoint string, ...) (tracer *trace.TracerProvider)
- func Middleware(opts ...Option) fiber.Handler
- type Option
- func WithCollectClientIP(collect bool) Option
- func WithCustomAttributes(f func(ctx *fiber.Ctx) []attribute.KeyValue) Option
- func WithCustomMetricAttributes(f func(ctx *fiber.Ctx) []attribute.KeyValue) Option
- func WithMeterProvider(provider otelmetric.MeterProvider) Option
- func WithNext(f func(ctx *fiber.Ctx) bool) Option
- func WithPort(port int) Option
- func WithPropagators(propagators propagation.TextMapPropagator) Option
- func WithServerName(serverName string) Option
- func WithSpanNameFormatter(f func(ctx *fiber.Ctx) string) Option
- func WithTracerProvider(provider oteltrace.TracerProvider) Option
Constants ¶
View Source
const ( MetricNameHttpServerDuration = "http.server.duration" MetricNameHttpServerRequestSize = "http.server.request.size" MetricNameHttpServerResponseSize = "http.server.response.size" MetricNameHttpServerActiveRequests = "http.server.active_requests" UnitDimensionless = "1" UnitBytes = "By" UnitMilliseconds = "ms" )
Variables ¶
This section is empty.
Functions ¶
func HasBasicAuth ¶
func Middleware ¶
func Middleware(opts ...Option) fiber.Handler
Types ¶
type Option ¶
type Option interface {
// contains filtered or unexported methods
}
func WithCollectClientIP ¶
func WithCustomAttributes ¶
func WithMeterProvider ¶
func WithMeterProvider(provider otelmetric.MeterProvider) Option
func WithPropagators ¶
func WithPropagators(propagators propagation.TextMapPropagator) Option
func WithServerName ¶
func WithSpanNameFormatter ¶
func WithTracerProvider ¶
func WithTracerProvider(provider oteltrace.TracerProvider) Option
Click to show internal directories.
Click to hide internal directories.