sentryotlp

package module
v0.49.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 26, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTraceExporter

func NewTraceExporter(ctx context.Context, dsn string, opts ...Option) (sdktrace.SpanExporter, error)

NewTraceExporter creates a new SpanExporter that sends spans to Sentry via the OTLP HTTP protocol.

The endpoint, URL path, headers, and HTTP/HTTPS mode are derived from the DSN.

Types

type Option

type Option func(*config)

Option configures safe OTLP HTTP client behavior for the Sentry exporter. Target selection and auth remain derived from the DSN.

func WithCompression

func WithCompression(compression otlptracehttp.Compression) Option

WithCompression configures OTLP payload compression.

func WithProxy added in v0.49.0

WithProxy configures the HTTP proxy function used for OTLP export requests.

If not set, the exporter falls back to [http.ProxyFromEnvironment] (i.e. HTTP_PROXY/HTTPS_PROXY). See otlptracehttp.WithProxy for details.

func WithRetry

func WithRetry(rc otlptracehttp.RetryConfig) Option

WithRetry configures OTLP retry behavior.

func WithTLSClientConfig

func WithTLSClientConfig(tlsCfg *tls.Config) Option

WithTLSClientConfig configures the HTTP client's TLS settings.

func WithTimeout

func WithTimeout(duration time.Duration) Option

WithTimeout configures the OTLP export timeout.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL