Documentation ¶
Index ¶
- func Count[N Number](ctx context.Context, meter metric.Meter, name string, value N, ...)
- func Start(ctx context.Context, otelServiceName string, apiReader client.Reader, ...) func()
- func StartSpan[T any](ctx context.Context, tracer T, opts ...trace.SpanStartOption) (context.Context, trace.Span)
- type Number
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Count ¶
func Count[N Number](ctx context.Context, meter metric.Meter, name string, value N, attributes ...attribute.KeyValue)
Count is a utility that can be used to increase Int64 and Float64 counters, but with same safeguards to avoid panics, if meter is not properly initialized
func Start ¶
func Start(ctx context.Context, otelServiceName string, apiReader client.Reader, webhookNamespace string) func()
Start sets up and starts all components needed for creating OpenTelemetry traces and metrics as well as some common auto-instrumentation It logs and swallows all errors to not prevent the application from startup.
Types ¶
Click to show internal directories.
Click to hide internal directories.