Documentation ¶
Overview ¶
This is a modified version of https://pkg.go.dev/golang.org/x/exp/event@v0.0.0-20230817173708-d852ddb80c63/otel, since the supported OTEL package is no longer the latest.
This is a modified version of https://pkg.go.dev/golang.org/x/exp/event@v0.0.0-20230817173708-d852ddb80c63/otel, since the supported OTEL package is no longer the latest.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MetricHandler ¶
type MetricHandler struct {
// contains filtered or unexported fields
}
MetricHandler is an event.Handler for OpenTelemetry metrics. Its Event method handles Metric events and ignores all others.
func NewMetricHandler ¶
func NewMetricHandler(m metric.Meter) *MetricHandler
NewMetricHandler creates a new MetricHandler.
type MultiHandler ¶
type MultiHandler struct { Metric handler Trace handler Log handler }
type PrometheusHandler ¶
type PrometheusHandler struct {
// contains filtered or unexported fields
}
PrometheusHandler is an event.Handler for OpenTelemetry metrics. Its Event method handles Metric events and ignores all others.
func NewPrometheusHandler ¶
func NewPrometheusHandler(client prometheus.Registerer) *PrometheusHandler
NewPrometheusHandler creates a new PrometheusHandler.
func (*PrometheusHandler) Collector ¶
func (m *PrometheusHandler) Collector(name string) prometheus.Collector
type SlogHandler ¶
type SlogHandler struct {
// contains filtered or unexported fields
}
func NewSlogHandler ¶
func NewSlogHandler(logger *slog.Logger) *SlogHandler