Documentation ¶
Overview ¶
This package allows you to init and enable tracing in your app
Index ¶
- func InitProvider(ctx context.Context, serviceName string, options ...ProviderOptionFunc) (func() error, error)
- func Start(ctx context.Context, appName string, host string, port int, apiKey string, ...) (func(ctx context.Context) error, error)
- func WithBatchSize(size int) func(*provider) error
- func WithGRPCTraceExporter(ctx context.Context, options ...otlptracegrpc.Option) func(*provider) error
- func WithWriterTraceExporter(w io.Writer) func(*provider) error
- type ProviderOptionFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitProvider ¶
func WithBatchSize ¶
WithBatchSize allows you to modify the batch size before it is sent
func WithGRPCTraceExporter ¶
func WithGRPCTraceExporter(ctx context.Context, options ...otlptracegrpc.Option) func(*provider) error
WithGRPCTraceExporter allows you to send your traces to the collector target collectorTarget is the address of the collector, e.g. "127.0.0.1:4317"
func WithWriterTraceExporter ¶
WithWriterTraceExporter allows you to push all traces to an io.Writer you can use io.Discard if you don't want to be bothered by these
Types ¶
type ProviderOptionFunc ¶
type ProviderOptionFunc func(*provider) error
ProviderOptionFunc is the option function for provider
Source Files ¶
Click to show internal directories.
Click to hide internal directories.