Documentation ¶
Index ¶
- type ExporterProvider
- type GRPCOptions
- type HTTPOptions
- type Metric
- type Option
- func Attributes(attrs ...attribute.KeyValue) Option
- func GRPC(gRPCOptions *GRPCOptions) Option
- func HTTP(httpOptions *HTTPOptions) Option
- func Prometheus(prometheusOptions *PrometheusOptions) Option
- func Resources(res resourcex.ResourceFlag) Option
- func Service(svc *resourcex.Service) Option
- func View(views ...ViewOption) Option
- func Writer(writerOptions *WriterOptions) Option
- type PrometheusOptions
- type ViewOption
- type WriterOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ExporterProvider ¶
type GRPCOptions ¶
type GRPCOptions struct { Endpoint string Insecure bool TLSConfig *tls.Config Headers map[string]string Compressor string DialOptions []grpc.DialOption GRPCConn *grpc.ClientConn ReconnectionPeriod time.Duration Retry *otlpmetricgrpc.RetryConfig Timeout time.Duration ServiceConfig string TemporalitySelector sdkmetric.TemporalitySelector AggregationSelector sdkmetric.AggregationSelector PeriodicReaderTimeout time.Duration PeriodicReaderInterval time.Duration }
type HTTPOptions ¶
type HTTPOptions struct { Endpoint string URLPath string Compression otlpmetrichttp.Compression TLSConfig *tls.Config Insecure bool Headers map[string]string Timeout time.Duration Retry *otlpmetrichttp.RetryConfig TemporalitySelector sdkmetric.TemporalitySelector AggregationSelector sdkmetric.AggregationSelector PeriodicReaderTimeout time.Duration PeriodicReaderInterval time.Duration }
type Metric ¶
type Metric struct {
// contains filtered or unexported fields
}
func (*Metric) MeterProvider ¶
func (metric *Metric) MeterProvider() metric.MeterProvider
type Option ¶
type Option func(o *options)
func Attributes ¶
func GRPC ¶
func GRPC(gRPCOptions *GRPCOptions) Option
func HTTP ¶
func HTTP(httpOptions *HTTPOptions) Option
func Prometheus ¶
func Prometheus(prometheusOptions *PrometheusOptions) Option
func Resources ¶
func Resources(res resourcex.ResourceFlag) Option
func View ¶
func View(views ...ViewOption) Option
func Writer ¶
func Writer(writerOptions *WriterOptions) Option
type PrometheusOptions ¶
type PrometheusOptions struct { Registerer prome.Registerer Aggregation metric.AggregationSelector WithoutUnits bool WithoutTargetInfo bool WithoutScopeInfo bool }
type ViewOption ¶
type ViewOption struct { Criteria sdkmetric.Instrument Mask sdkmetric.Stream }
type WriterOptions ¶
type WriterOptions struct { // Writer 标准输入或者文件 Writer io.Writer NewEncoder func(writer io.Writer) stdoutmetric.Encoder TemporalitySelector sdkmetric.TemporalitySelector AggregationSelector sdkmetric.AggregationSelector PeriodicReaderTimeout time.Duration PeriodicReaderInterval time.Duration }
Click to show internal directories.
Click to hide internal directories.