Documentation ¶
Overview ¶
Package otel contains an o11y.Provider that emits open telemetry gRPC. N.B. This has not been tried against a production collector, so we need to try it out on a safe / non production traffic service.
Index ¶
- func New(conf Config) (o11y.Provider, error)
- type Annotator
- type Config
- type Provider
- func (o Provider) AddField(ctx context.Context, key string, val any)
- func (o Provider) AddFieldToTrace(ctx context.Context, key string, val any)
- func (o Provider) AddGlobalField(key string, val any)
- func (o Provider) Close(ctx context.Context)
- func (o Provider) GetSpan(ctx context.Context) o11y.Span
- func (o Provider) Helpers(disableW3c ...bool) o11y.Helpers
- func (o Provider) Log(ctx context.Context, name string, fields ...o11y.Pair)
- func (o Provider) MetricsProvider() o11y.MetricsProvider
- func (o *Provider) RawProvider() *Provider
- func (o Provider) StartSpan(ctx context.Context, name string) (context.Context, o11y.Span)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Annotator ¶
type Annotator struct {
// contains filtered or unexported fields
}
Annotator is a SpanProcessor that adds attributes to all started spans.
func (Annotator) OnEnd ¶
func (a Annotator) OnEnd(s sdktrace.ReadOnlySpan)
type Provider ¶
type Provider struct {
// contains filtered or unexported fields
}
func (Provider) AddFieldToTrace ¶
func (Provider) AddGlobalField ¶
func (Provider) GetSpan ¶
GetSpan returns the active span in the given context. It will return nil if there is no span available.
func (Provider) MetricsProvider ¶
func (o Provider) MetricsProvider() o11y.MetricsProvider
func (*Provider) RawProvider ¶
RawProvider satisfies an interface the helpers need
Source Files ¶
Click to show internal directories.
Click to hide internal directories.