xotel

package module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2023 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultProvider

func DefaultProvider() tracing.Provider

默认的otel provider实现

func New

func New(option *Option) tracing.Provider

func NewProvider

func NewProvider(option *Option, exp sdktrace.SpanExporter) tracing.Provider

TODO: 后续提供 resource sampler idGenerator spanlimits的可定制化 SpanExporter 将otel生成的span数据做转化并上报到相应的collector,比如zipkin jaeger Sampler 采样器 IDGenerator spanid traceid生成器 SpanLimits 限制event attribute的数量

Types

type Option

type Option struct {
	// 服务名
	ServiceName string
	// collector地址
	Endpoint string
	// 支持jaeger,otel,stdout
	// 默认 stdout
	ExporterName string
	// sample 采样率 0 < x<=1
	SamplerRatio float64
}

func DefaultOption

func DefaultOption() *Option

Jump to

Keyboard shortcuts

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