diff --git a/otelconf/generated_config.go b/otelconf/generated_config.go index 6c508e9b030..b3d5b08d4e0 100644 --- a/otelconf/generated_config.go +++ b/otelconf/generated_config.go @@ -3,24 +3,22 @@ package otelconf type Aggregation struct { - // Base2ExponentialBucketHistogram corresponds to the JSON schema field - // "base2_exponential_bucket_histogram". + // TODO Base2ExponentialBucketHistogram *Base2ExponentialBucketHistogramAggregation `json:"base2_exponential_bucket_histogram,omitempty" yaml:"base2_exponential_bucket_histogram,omitempty" mapstructure:"base2_exponential_bucket_histogram,omitempty"` - // Default corresponds to the JSON schema field "default". + // TODO Default DefaultAggregation `json:"default,omitempty" yaml:"default,omitempty" mapstructure:"default,omitempty"` - // Drop corresponds to the JSON schema field "drop". + // TODO Drop DropAggregation `json:"drop,omitempty" yaml:"drop,omitempty" mapstructure:"drop,omitempty"` - // ExplicitBucketHistogram corresponds to the JSON schema field - // "explicit_bucket_histogram". + // Configure aggregation to be explicit_bucket_histogram. ExplicitBucketHistogram *ExplicitBucketHistogramAggregation `json:"explicit_bucket_histogram,omitempty" yaml:"explicit_bucket_histogram,omitempty" mapstructure:"explicit_bucket_histogram,omitempty"` - // LastValue corresponds to the JSON schema field "last_value". + // TODO LastValue LastValueAggregation `json:"last_value,omitempty" yaml:"last_value,omitempty" mapstructure:"last_value,omitempty"` - // Sum corresponds to the JSON schema field "sum". + // TODO Sum SumAggregation `json:"sum,omitempty" yaml:"sum,omitempty" mapstructure:"sum,omitempty"` } @@ -29,31 +27,54 @@ type AlwaysOffSampler map[string]interface{} type AlwaysOnSampler map[string]interface{} type AttributeLimits struct { - // AttributeCountLimit corresponds to the JSON schema field - // "attribute_count_limit". - AttributeCountLimit *int `json:"attribute_count_limit,omitempty" yaml:"attribute_count_limit,omitempty" mapstructure:"attribute_count_limit,omitempty"` + // Configure max attribute count. + // Value must be non-negative. + // If omitted or null, 128 is used. + AttributeCountLimit AttributeLimitsAttributeCountLimit `json:"attribute_count_limit,omitempty" yaml:"attribute_count_limit,omitempty" mapstructure:"attribute_count_limit,omitempty"` - // AttributeValueLengthLimit corresponds to the JSON schema field - // "attribute_value_length_limit". - AttributeValueLengthLimit *int `json:"attribute_value_length_limit,omitempty" yaml:"attribute_value_length_limit,omitempty" mapstructure:"attribute_value_length_limit,omitempty"` - - AdditionalProperties interface{} `mapstructure:",remain"` + // Configure max attribute value size. + // Value must be non-negative. + // If omitted or null, there is no limit. + AttributeValueLengthLimit AttributeLimitsAttributeValueLengthLimit `json:"attribute_value_length_limit,omitempty" yaml:"attribute_value_length_limit,omitempty" mapstructure:"attribute_value_length_limit,omitempty"` } +// Configure max attribute count. +// +// Value must be non-negative. +// If omitted or null, 128 is used. +type AttributeLimitsAttributeCountLimit *int + +// Configure max attribute value size. +// +// Value must be non-negative. +// If omitted or null, there is no limit. +type AttributeLimitsAttributeValueLengthLimit *int + type AttributeNameValue struct { - // Name corresponds to the JSON schema field "name". + // The attribute name. Name string `json:"name" yaml:"name" mapstructure:"name"` - // Type corresponds to the JSON schema field "type". + // The attribute type. + // Values include: string, bool, int, double, string_array, bool_array, + // int_array, double_array. + // If omitted or null, string is used. Type *AttributeType `json:"type,omitempty" yaml:"type,omitempty" mapstructure:"type,omitempty"` - // Value corresponds to the JSON schema field "value". + // The attribute value. + // The type of value must match .type. Value interface{} `json:"value" yaml:"value" mapstructure:"value"` } -type AttributeType struct { - Value interface{} -} +type AttributeType string + +const AttributeTypeBool AttributeType = "bool" +const AttributeTypeBoolArray AttributeType = "bool_array" +const AttributeTypeDouble AttributeType = "double" +const AttributeTypeDoubleArray AttributeType = "double_array" +const AttributeTypeInt AttributeType = "int" +const AttributeTypeIntArray AttributeType = "int_array" +const AttributeTypeString AttributeType = "string" +const AttributeTypeStringArray AttributeType = "string_array" type B3MultiPropagator map[string]interface{} @@ -62,81 +83,208 @@ type B3Propagator map[string]interface{} type BaggagePropagator map[string]interface{} type Base2ExponentialBucketHistogramAggregation struct { - // MaxScale corresponds to the JSON schema field "max_scale". - MaxScale *int `json:"max_scale,omitempty" yaml:"max_scale,omitempty" mapstructure:"max_scale,omitempty"` + // TODO + MaxScale Base2ExponentialBucketHistogramAggregationMaxScale `json:"max_scale,omitempty" yaml:"max_scale,omitempty" mapstructure:"max_scale,omitempty"` - // MaxSize corresponds to the JSON schema field "max_size". - MaxSize *int `json:"max_size,omitempty" yaml:"max_size,omitempty" mapstructure:"max_size,omitempty"` + // TODO + MaxSize Base2ExponentialBucketHistogramAggregationMaxSize `json:"max_size,omitempty" yaml:"max_size,omitempty" mapstructure:"max_size,omitempty"` - // RecordMinMax corresponds to the JSON schema field "record_min_max". - RecordMinMax *bool `json:"record_min_max,omitempty" yaml:"record_min_max,omitempty" mapstructure:"record_min_max,omitempty"` + // TODO + RecordMinMax Base2ExponentialBucketHistogramAggregationRecordMinMax `json:"record_min_max,omitempty" yaml:"record_min_max,omitempty" mapstructure:"record_min_max,omitempty"` } +// TODO +type Base2ExponentialBucketHistogramAggregationMaxScale *int + +// TODO +type Base2ExponentialBucketHistogramAggregationMaxSize *int + +// TODO +type Base2ExponentialBucketHistogramAggregationRecordMinMax *bool + type BatchLogRecordProcessor struct { - // ExportTimeout corresponds to the JSON schema field "export_timeout". - ExportTimeout *int `json:"export_timeout,omitempty" yaml:"export_timeout,omitempty" mapstructure:"export_timeout,omitempty"` + // Configure maximum allowed time (in milliseconds) to export data. + // Value must be non-negative. A value of 0 indicates no limit (infinity). + // If omitted or null, 30000 is used. + ExportTimeout BatchLogRecordProcessorExportTimeout `json:"export_timeout,omitempty" yaml:"export_timeout,omitempty" mapstructure:"export_timeout,omitempty"` - // Exporter corresponds to the JSON schema field "exporter". + // Configure exporter. Exporter LogRecordExporter `json:"exporter" yaml:"exporter" mapstructure:"exporter"` - // MaxExportBatchSize corresponds to the JSON schema field - // "max_export_batch_size". - MaxExportBatchSize *int `json:"max_export_batch_size,omitempty" yaml:"max_export_batch_size,omitempty" mapstructure:"max_export_batch_size,omitempty"` + // Configure maximum batch size. Value must be positive. + // If omitted or null, 512 is used. + MaxExportBatchSize BatchLogRecordProcessorMaxExportBatchSize `json:"max_export_batch_size,omitempty" yaml:"max_export_batch_size,omitempty" mapstructure:"max_export_batch_size,omitempty"` - // MaxQueueSize corresponds to the JSON schema field "max_queue_size". - MaxQueueSize *int `json:"max_queue_size,omitempty" yaml:"max_queue_size,omitempty" mapstructure:"max_queue_size,omitempty"` + // Configure maximum queue size. Value must be positive. + // If omitted or null, 2048 is used. + MaxQueueSize BatchLogRecordProcessorMaxQueueSize `json:"max_queue_size,omitempty" yaml:"max_queue_size,omitempty" mapstructure:"max_queue_size,omitempty"` - // ScheduleDelay corresponds to the JSON schema field "schedule_delay". - ScheduleDelay *int `json:"schedule_delay,omitempty" yaml:"schedule_delay,omitempty" mapstructure:"schedule_delay,omitempty"` + // Configure delay interval (in milliseconds) between two consecutive exports. + // Value must be non-negative. + // If omitted or null, 1000 is used. + ScheduleDelay BatchLogRecordProcessorScheduleDelay `json:"schedule_delay,omitempty" yaml:"schedule_delay,omitempty" mapstructure:"schedule_delay,omitempty"` } +// Configure maximum allowed time (in milliseconds) to export data. +// +// Value must be non-negative. A value of 0 indicates no limit (infinity). +// If omitted or null, 30000 is used. +type BatchLogRecordProcessorExportTimeout *int + +// Configure maximum batch size. Value must be positive. +// +// If omitted or null, 512 is used. +type BatchLogRecordProcessorMaxExportBatchSize *int + +// Configure maximum queue size. Value must be positive. +// +// If omitted or null, 2048 is used. +type BatchLogRecordProcessorMaxQueueSize *int + +// Configure delay interval (in milliseconds) between two consecutive exports. +// +// Value must be non-negative. +// If omitted or null, 1000 is used. +type BatchLogRecordProcessorScheduleDelay *int + type BatchSpanProcessor struct { - // ExportTimeout corresponds to the JSON schema field "export_timeout". - ExportTimeout *int `json:"export_timeout,omitempty" yaml:"export_timeout,omitempty" mapstructure:"export_timeout,omitempty"` + // Configure maximum allowed time (in milliseconds) to export data. + // Value must be non-negative. A value of 0 indicates no limit (infinity). + // If omitted or null, 30000 is used. + ExportTimeout BatchSpanProcessorExportTimeout `json:"export_timeout,omitempty" yaml:"export_timeout,omitempty" mapstructure:"export_timeout,omitempty"` - // Exporter corresponds to the JSON schema field "exporter". + // Configure exporter. Exporter SpanExporter `json:"exporter" yaml:"exporter" mapstructure:"exporter"` - // MaxExportBatchSize corresponds to the JSON schema field - // "max_export_batch_size". - MaxExportBatchSize *int `json:"max_export_batch_size,omitempty" yaml:"max_export_batch_size,omitempty" mapstructure:"max_export_batch_size,omitempty"` + // Configure maximum batch size. Value must be positive. + // If omitted or null, 512 is used. + MaxExportBatchSize BatchSpanProcessorMaxExportBatchSize `json:"max_export_batch_size,omitempty" yaml:"max_export_batch_size,omitempty" mapstructure:"max_export_batch_size,omitempty"` - // MaxQueueSize corresponds to the JSON schema field "max_queue_size". - MaxQueueSize *int `json:"max_queue_size,omitempty" yaml:"max_queue_size,omitempty" mapstructure:"max_queue_size,omitempty"` + // Configure maximum queue size. Value must be positive. + // If omitted or null, 2048 is used. + MaxQueueSize BatchSpanProcessorMaxQueueSize `json:"max_queue_size,omitempty" yaml:"max_queue_size,omitempty" mapstructure:"max_queue_size,omitempty"` - // ScheduleDelay corresponds to the JSON schema field "schedule_delay". - ScheduleDelay *int `json:"schedule_delay,omitempty" yaml:"schedule_delay,omitempty" mapstructure:"schedule_delay,omitempty"` + // Configure delay interval (in milliseconds) between two consecutive exports. + // Value must be non-negative. + // If omitted or null, 5000 is used. + ScheduleDelay BatchSpanProcessorScheduleDelay `json:"schedule_delay,omitempty" yaml:"schedule_delay,omitempty" mapstructure:"schedule_delay,omitempty"` } -type CardinalityLimits struct { - // Counter corresponds to the JSON schema field "counter". - Counter *int `json:"counter,omitempty" yaml:"counter,omitempty" mapstructure:"counter,omitempty"` +// Configure maximum allowed time (in milliseconds) to export data. +// +// Value must be non-negative. A value of 0 indicates no limit (infinity). +// If omitted or null, 30000 is used. +type BatchSpanProcessorExportTimeout *int - // Default corresponds to the JSON schema field "default". - Default *int `json:"default,omitempty" yaml:"default,omitempty" mapstructure:"default,omitempty"` +// Configure maximum batch size. Value must be positive. +// +// If omitted or null, 512 is used. +type BatchSpanProcessorMaxExportBatchSize *int - // Gauge corresponds to the JSON schema field "gauge". - Gauge *int `json:"gauge,omitempty" yaml:"gauge,omitempty" mapstructure:"gauge,omitempty"` +// Configure maximum queue size. Value must be positive. +// +// If omitted or null, 2048 is used. +type BatchSpanProcessorMaxQueueSize *int - // Histogram corresponds to the JSON schema field "histogram". - Histogram *int `json:"histogram,omitempty" yaml:"histogram,omitempty" mapstructure:"histogram,omitempty"` +// Configure delay interval (in milliseconds) between two consecutive exports. +// +// Value must be non-negative. +// If omitted or null, 5000 is used. +type BatchSpanProcessorScheduleDelay *int - // ObservableCounter corresponds to the JSON schema field "observable_counter". - ObservableCounter *int `json:"observable_counter,omitempty" yaml:"observable_counter,omitempty" mapstructure:"observable_counter,omitempty"` +type CardinalityLimits struct { + // Configure default cardinality limit for counter instruments. + // If omitted or null, the value from .default is used. + Counter CardinalityLimitsCounter `json:"counter,omitempty" yaml:"counter,omitempty" mapstructure:"counter,omitempty"` + + // Configure default cardinality limit for all instrument types. + // Instrument-specific cardinality limits take priority. + // If omitted or null, 2000 is used. + Default CardinalityLimitsDefault `json:"default,omitempty" yaml:"default,omitempty" mapstructure:"default,omitempty"` + + // Configure default cardinality limit for gauge instruments. + // If omitted or null, the value from .default is used. + Gauge CardinalityLimitsGauge `json:"gauge,omitempty" yaml:"gauge,omitempty" mapstructure:"gauge,omitempty"` + + // Configure default cardinality limit for histogram instruments. + // If omitted or null, the value from .default is used. + Histogram CardinalityLimitsHistogram `json:"histogram,omitempty" yaml:"histogram,omitempty" mapstructure:"histogram,omitempty"` + + // Configure default cardinality limit for observable_counter instruments. + // If omitted or null, the value from .default is used. + ObservableCounter CardinalityLimitsObservableCounter `json:"observable_counter,omitempty" yaml:"observable_counter,omitempty" mapstructure:"observable_counter,omitempty"` + + // Configure default cardinality limit for observable_gauge instruments. + // If omitted or null, the value from .default is used. + ObservableGauge CardinalityLimitsObservableGauge `json:"observable_gauge,omitempty" yaml:"observable_gauge,omitempty" mapstructure:"observable_gauge,omitempty"` + + // Configure default cardinality limit for observable_up_down_counter instruments. + // If omitted or null, the value from .default is used. + ObservableUpDownCounter CardinalityLimitsObservableUpDownCounter `json:"observable_up_down_counter,omitempty" yaml:"observable_up_down_counter,omitempty" mapstructure:"observable_up_down_counter,omitempty"` + + // Configure default cardinality limit for up_down_counter instruments. + // If omitted or null, the value from .default is used. + UpDownCounter CardinalityLimitsUpDownCounter `json:"up_down_counter,omitempty" yaml:"up_down_counter,omitempty" mapstructure:"up_down_counter,omitempty"` +} + +// Configure default cardinality limit for counter instruments. +// +// If omitted or null, the value from .default is used. +type CardinalityLimitsCounter *int + +// Configure default cardinality limit for all instrument types. +// +// Instrument-specific cardinality limits take priority. +// If omitted or null, 2000 is used. +type CardinalityLimitsDefault *int + +// Configure default cardinality limit for gauge instruments. +// +// If omitted or null, the value from .default is used. +type CardinalityLimitsGauge *int + +// Configure default cardinality limit for histogram instruments. +// +// If omitted or null, the value from .default is used. +type CardinalityLimitsHistogram *int + +// Configure default cardinality limit for observable_counter instruments. +// +// If omitted or null, the value from .default is used. +type CardinalityLimitsObservableCounter *int + +// Configure default cardinality limit for observable_gauge instruments. +// +// If omitted or null, the value from .default is used. +type CardinalityLimitsObservableGauge *int + +// Configure default cardinality limit for observable_up_down_counter instruments. +// +// If omitted or null, the value from .default is used. +type CardinalityLimitsObservableUpDownCounter *int + +// Configure default cardinality limit for up_down_counter instruments. +// +// If omitted or null, the value from .default is used. +type CardinalityLimitsUpDownCounter *int - // ObservableGauge corresponds to the JSON schema field "observable_gauge". - ObservableGauge *int `json:"observable_gauge,omitempty" yaml:"observable_gauge,omitempty" mapstructure:"observable_gauge,omitempty"` +type ConsoleExporter map[string]interface{} - // ObservableUpDownCounter corresponds to the JSON schema field - // "observable_up_down_counter". - ObservableUpDownCounter *int `json:"observable_up_down_counter,omitempty" yaml:"observable_up_down_counter,omitempty" mapstructure:"observable_up_down_counter,omitempty"` +type ConsoleMetricExporter struct { + // Configure default histogram aggregation. + // Values include: explicit_bucket_histogram, base2_exponential_bucket_histogram. + // For behavior of values, see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md. + // If omitted or null, explicit_bucket_histogram is used. + DefaultHistogramAggregation *ExporterDefaultHistogramAggregation `json:"default_histogram_aggregation,omitempty" yaml:"default_histogram_aggregation,omitempty" mapstructure:"default_histogram_aggregation,omitempty"` - // UpDownCounter corresponds to the JSON schema field "up_down_counter". - UpDownCounter *int `json:"up_down_counter,omitempty" yaml:"up_down_counter,omitempty" mapstructure:"up_down_counter,omitempty"` + // Configure temporality preference. + // Values include: cumulative, delta, low_memory. For behavior of values, see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md. + // If omitted or null, cumulative is used. + TemporalityPreference *ExporterTemporalityPreference `json:"temporality_preference,omitempty" yaml:"temporality_preference,omitempty" mapstructure:"temporality_preference,omitempty"` } -type ConsoleExporter map[string]interface{} - type DefaultAggregation map[string]interface{} type DropAggregation map[string]interface{} @@ -147,142 +295,283 @@ const ExemplarFilterAlwaysOff ExemplarFilter = "always_off" const ExemplarFilterAlwaysOn ExemplarFilter = "always_on" const ExemplarFilterTraceBased ExemplarFilter = "trace_based" +type ExperimentalComposableAlwaysOffSampler map[string]interface{} + +type ExperimentalComposableAlwaysOnSampler map[string]interface{} + +type ExperimentalComposableParentBasedSampler struct { + // Configures the sampler for spans with a local parent that is not sampled. + LocalParentNotSampled *ExperimentalComposableSampler `json:"local_parent_not_sampled,omitempty" yaml:"local_parent_not_sampled,omitempty" mapstructure:"local_parent_not_sampled,omitempty"` + + // Configures the sampler for spans with a local parent that is sampled. + LocalParentSampled *ExperimentalComposableSampler `json:"local_parent_sampled,omitempty" yaml:"local_parent_sampled,omitempty" mapstructure:"local_parent_sampled,omitempty"` + + // Configures the sampler for spans with a remote parent that is not sampled. + RemoteParentNotSampled *ExperimentalComposableSampler `json:"remote_parent_not_sampled,omitempty" yaml:"remote_parent_not_sampled,omitempty" mapstructure:"remote_parent_not_sampled,omitempty"` + + // Configures the sampler for spans with a remote parent that is sampled. + RemoteParentSampled *ExperimentalComposableSampler `json:"remote_parent_sampled,omitempty" yaml:"remote_parent_sampled,omitempty" mapstructure:"remote_parent_sampled,omitempty"` + + // Configures the sampler for spans with no parent. + Root *ExperimentalComposableSampler `json:"root,omitempty" yaml:"root,omitempty" mapstructure:"root,omitempty"` +} + +type ExperimentalComposableProbabilitySampler struct { + // Configure ratio. + // If omitted or null, 1.0 is used. + Ratio ExperimentalComposableProbabilitySamplerRatio `json:"ratio,omitempty" yaml:"ratio,omitempty" mapstructure:"ratio,omitempty"` +} + +// Configure ratio. +// +// If omitted or null, 1.0 is used. +type ExperimentalComposableProbabilitySamplerRatio *float64 + +type ExperimentalComposableSampler struct { + // Configure sampler to be always_off. + AlwaysOff ExperimentalComposableAlwaysOffSampler `json:"always_off,omitempty" yaml:"always_off,omitempty" mapstructure:"always_off,omitempty"` + + // Configure sampler to be always_on. + AlwaysOn ExperimentalComposableAlwaysOnSampler `json:"always_on,omitempty" yaml:"always_on,omitempty" mapstructure:"always_on,omitempty"` + + // Configure sampler to be parent_based. + ParentBased *ExperimentalComposableParentBasedSampler `json:"parent_based,omitempty" yaml:"parent_based,omitempty" mapstructure:"parent_based,omitempty"` + + // Configure sampler to be probability. + Probability *ExperimentalComposableProbabilitySampler `json:"probability,omitempty" yaml:"probability,omitempty" mapstructure:"probability,omitempty"` + + AdditionalProperties interface{} `mapstructure:",remain"` +} + type ExperimentalContainerResourceDetector map[string]interface{} type ExperimentalGeneralInstrumentation struct { - // Http corresponds to the JSON schema field "http". + // Configure instrumentations following the http semantic conventions. + // See http semantic conventions: + // https://opentelemetry.io/docs/specs/semconv/http/ Http *ExperimentalHttpInstrumentation `json:"http,omitempty" yaml:"http,omitempty" mapstructure:"http,omitempty"` - // Peer corresponds to the JSON schema field "peer". + // Configure instrumentations following the peer semantic conventions. + // See peer semantic conventions: + // https://opentelemetry.io/docs/specs/semconv/attributes-registry/peer/ Peer *ExperimentalPeerInstrumentation `json:"peer,omitempty" yaml:"peer,omitempty" mapstructure:"peer,omitempty"` } type ExperimentalHostResourceDetector map[string]interface{} +type ExperimentalHttpClientInstrumentation struct { + // Configure headers to capture for outbound http requests. + RequestCapturedHeaders []string `json:"request_captured_headers,omitempty" yaml:"request_captured_headers,omitempty" mapstructure:"request_captured_headers,omitempty"` + + // Configure headers to capture for inbound http responses. + ResponseCapturedHeaders []string `json:"response_captured_headers,omitempty" yaml:"response_captured_headers,omitempty" mapstructure:"response_captured_headers,omitempty"` +} + type ExperimentalHttpInstrumentation struct { - // Client corresponds to the JSON schema field "client". - Client *ExperimentalHttpInstrumentationClient `json:"client,omitempty" yaml:"client,omitempty" mapstructure:"client,omitempty"` + // Configure instrumentations following the http client semantic conventions. + Client *ExperimentalHttpClientInstrumentation `json:"client,omitempty" yaml:"client,omitempty" mapstructure:"client,omitempty"` - // Server corresponds to the JSON schema field "server". - Server *ExperimentalHttpInstrumentationServer `json:"server,omitempty" yaml:"server,omitempty" mapstructure:"server,omitempty"` + // Configure instrumentations following the http server semantic conventions. + Server *ExperimentalHttpServerInstrumentation `json:"server,omitempty" yaml:"server,omitempty" mapstructure:"server,omitempty"` } -type ExperimentalHttpInstrumentationClient struct { - // RequestCapturedHeaders corresponds to the JSON schema field - // "request_captured_headers". +type ExperimentalHttpServerInstrumentation struct { + // Configure headers to capture for inbound http requests. RequestCapturedHeaders []string `json:"request_captured_headers,omitempty" yaml:"request_captured_headers,omitempty" mapstructure:"request_captured_headers,omitempty"` - // ResponseCapturedHeaders corresponds to the JSON schema field - // "response_captured_headers". + // Configure headers to capture for outbound http responses. ResponseCapturedHeaders []string `json:"response_captured_headers,omitempty" yaml:"response_captured_headers,omitempty" mapstructure:"response_captured_headers,omitempty"` } -type ExperimentalHttpInstrumentationServer struct { - // RequestCapturedHeaders corresponds to the JSON schema field - // "request_captured_headers". - RequestCapturedHeaders []string `json:"request_captured_headers,omitempty" yaml:"request_captured_headers,omitempty" mapstructure:"request_captured_headers,omitempty"` +type ExperimentalJaegerRemoteSampler struct { + // TODO + Endpoint ExperimentalJaegerRemoteSamplerEndpoint `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` - // ResponseCapturedHeaders corresponds to the JSON schema field - // "response_captured_headers". - ResponseCapturedHeaders []string `json:"response_captured_headers,omitempty" yaml:"response_captured_headers,omitempty" mapstructure:"response_captured_headers,omitempty"` + // TODO + InitialSampler *Sampler `json:"initial_sampler,omitempty" yaml:"initial_sampler,omitempty" mapstructure:"initial_sampler,omitempty"` + + // TODO + Interval ExperimentalJaegerRemoteSamplerInterval `json:"interval,omitempty" yaml:"interval,omitempty" mapstructure:"interval,omitempty"` } -type ExperimentalLanguageSpecificInstrumentation map[string]interface{} +// TODO +type ExperimentalJaegerRemoteSamplerEndpoint *string + +// TODO +type ExperimentalJaegerRemoteSamplerInterval *int + +type ExperimentalLanguageSpecificInstrumentation map[string]map[string]interface{} type ExperimentalLoggerConfig struct { - // Disabled corresponds to the JSON schema field "disabled". + // Configure if the logger is enabled or not. Disabled *bool `json:"disabled,omitempty" yaml:"disabled,omitempty" mapstructure:"disabled,omitempty"` } type ExperimentalLoggerConfigurator struct { - // DefaultConfig corresponds to the JSON schema field "default_config". + // Configure the default logger config used there is no matching entry in + // .logger_configurator/development.loggers. DefaultConfig *ExperimentalLoggerConfig `json:"default_config,omitempty" yaml:"default_config,omitempty" mapstructure:"default_config,omitempty"` - // Loggers corresponds to the JSON schema field "loggers". + // Configure loggers. Loggers []ExperimentalLoggerMatcherAndConfig `json:"loggers,omitempty" yaml:"loggers,omitempty" mapstructure:"loggers,omitempty"` } type ExperimentalLoggerMatcherAndConfig struct { - // Config corresponds to the JSON schema field "config". + // The logger config. Config *ExperimentalLoggerConfig `json:"config,omitempty" yaml:"config,omitempty" mapstructure:"config,omitempty"` - // Name corresponds to the JSON schema field "name". + // Configure logger names to match, evaluated as follows: + // * If the logger name exactly matches. + // * If the logger name matches the wildcard pattern, where '?' matches any + // single character and '*' matches any number of characters including none. Name *string `json:"name,omitempty" yaml:"name,omitempty" mapstructure:"name,omitempty"` } type ExperimentalMeterConfig struct { - // Disabled corresponds to the JSON schema field "disabled". + // Configure if the meter is enabled or not. Disabled *bool `json:"disabled,omitempty" yaml:"disabled,omitempty" mapstructure:"disabled,omitempty"` } type ExperimentalMeterConfigurator struct { - // DefaultConfig corresponds to the JSON schema field "default_config". + // Configure the default meter config used there is no matching entry in + // .meter_configurator/development.meters. DefaultConfig *ExperimentalMeterConfig `json:"default_config,omitempty" yaml:"default_config,omitempty" mapstructure:"default_config,omitempty"` - // Meters corresponds to the JSON schema field "meters". + // Configure meters. Meters []ExperimentalMeterMatcherAndConfig `json:"meters,omitempty" yaml:"meters,omitempty" mapstructure:"meters,omitempty"` } type ExperimentalMeterMatcherAndConfig struct { - // Config corresponds to the JSON schema field "config". + // The meter config. Config *ExperimentalMeterConfig `json:"config,omitempty" yaml:"config,omitempty" mapstructure:"config,omitempty"` - // Name corresponds to the JSON schema field "name". + // Configure meter names to match, evaluated as follows: + // + // * If the meter name exactly matches. + // * If the meter name matches the wildcard pattern, where '?' matches any + // single character and '*' matches any number of characters including none. Name *string `json:"name,omitempty" yaml:"name,omitempty" mapstructure:"name,omitempty"` } type ExperimentalOTLPFileExporter struct { - // OutputStream corresponds to the JSON schema field "output_stream". - OutputStream *string `json:"output_stream,omitempty" yaml:"output_stream,omitempty" mapstructure:"output_stream,omitempty"` -} + // Configure output stream. + // Values include stdout, or scheme+destination. For example: + // file:///path/to/file.jsonl. + // If omitted or null, stdout is used. + OutputStream ExperimentalOTLPFileExporterOutputStream `json:"output_stream,omitempty" yaml:"output_stream,omitempty" mapstructure:"output_stream,omitempty"` +} + +// Configure output stream. +// +// Values include stdout, or scheme+destination. For example: +// +// file:///path/to/file.jsonl. +// +// If omitted or null, stdout is used. +type ExperimentalOTLPFileExporterOutputStream *string type ExperimentalOTLPFileMetricExporter struct { - // DefaultHistogramAggregation corresponds to the JSON schema field - // "default_histogram_aggregation". + // Configure default histogram aggregation. + // Values include: explicit_bucket_histogram, base2_exponential_bucket_histogram. + // For behavior of values, see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md. + // If omitted or null, explicit_bucket_histogram is used. DefaultHistogramAggregation *ExporterDefaultHistogramAggregation `json:"default_histogram_aggregation,omitempty" yaml:"default_histogram_aggregation,omitempty" mapstructure:"default_histogram_aggregation,omitempty"` - // OutputStream corresponds to the JSON schema field "output_stream". - OutputStream *string `json:"output_stream,omitempty" yaml:"output_stream,omitempty" mapstructure:"output_stream,omitempty"` + // Configure output stream. + // Values include stdout, or scheme+destination. For example: + // file:///path/to/file.jsonl. + // If omitted or null, stdout is used. + OutputStream ExperimentalOTLPFileMetricExporterOutputStream `json:"output_stream,omitempty" yaml:"output_stream,omitempty" mapstructure:"output_stream,omitempty"` - // TemporalityPreference corresponds to the JSON schema field - // "temporality_preference". + // Configure temporality preference. + // Values include: cumulative, delta, low_memory. For behavior of values, see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md. + // If omitted or null, cumulative is used. TemporalityPreference *ExporterTemporalityPreference `json:"temporality_preference,omitempty" yaml:"temporality_preference,omitempty" mapstructure:"temporality_preference,omitempty"` } +// Configure output stream. +// +// Values include stdout, or scheme+destination. For example: +// +// file:///path/to/file.jsonl. +// +// If omitted or null, stdout is used. +type ExperimentalOTLPFileMetricExporterOutputStream *string + type ExperimentalPeerInstrumentation struct { - // ServiceMapping corresponds to the JSON schema field "service_mapping". - ServiceMapping []ExperimentalPeerInstrumentationServiceMappingElem `json:"service_mapping,omitempty" yaml:"service_mapping,omitempty" mapstructure:"service_mapping,omitempty"` + // Configure the service mapping for instrumentations following peer.service + // semantic conventions. + // See peer.service semantic conventions: + // https://opentelemetry.io/docs/specs/semconv/general/attributes/#general-remote-service-attributes + ServiceMapping []ExperimentalPeerServiceMapping `json:"service_mapping,omitempty" yaml:"service_mapping,omitempty" mapstructure:"service_mapping,omitempty"` } -type ExperimentalPeerInstrumentationServiceMappingElem struct { - // Peer corresponds to the JSON schema field "peer". +type ExperimentalPeerServiceMapping struct { + // The IP address to map. Peer string `json:"peer" yaml:"peer" mapstructure:"peer"` - // Service corresponds to the JSON schema field "service". + // The logical name corresponding to the IP address of .peer. Service string `json:"service" yaml:"service" mapstructure:"service"` } -type ExperimentalProcessResourceDetector map[string]interface{} +type ExperimentalProbabilitySampler struct { + // Configure ratio. + // If omitted or null, 1.0 is used. + Ratio ExperimentalProbabilitySamplerRatio `json:"ratio,omitempty" yaml:"ratio,omitempty" mapstructure:"ratio,omitempty"` +} -type ExperimentalPrometheusMetricExporter struct { - // Host corresponds to the JSON schema field "host". - Host *string `json:"host,omitempty" yaml:"host,omitempty" mapstructure:"host,omitempty"` +// Configure ratio. +// +// If omitted or null, 1.0 is used. +type ExperimentalProbabilitySamplerRatio *float64 - // Port corresponds to the JSON schema field "port". - Port *int `json:"port,omitempty" yaml:"port,omitempty" mapstructure:"port,omitempty"` +type ExperimentalProcessResourceDetector map[string]interface{} - // TranslationStrategy corresponds to the JSON schema field - // "translation_strategy". +type ExperimentalPrometheusMetricExporter struct { + // Configure host. + // If omitted or null, localhost is used. + Host ExperimentalPrometheusMetricExporterHost `json:"host,omitempty" yaml:"host,omitempty" mapstructure:"host,omitempty"` + + // Configure port. + // If omitted or null, 9464 is used. + Port ExperimentalPrometheusMetricExporterPort `json:"port,omitempty" yaml:"port,omitempty" mapstructure:"port,omitempty"` + + // Configure how Prometheus metrics are exposed. Values include: + // + // * UnderscoreEscapingWithSuffixes, the default. This fully escapes + // metric names for classic Prometheus metric name compatibility, and includes + // appending type and unit suffixes. + // * UnderscoreEscapingWithoutSuffixes, metric names will continue to + // escape special characters to _, but suffixes won't be attached. + // * NoUTF8EscapingWithSuffixes will disable changing special characters + // to _. Special suffixes like units and _total for counters will be attached. + // * NoTranslation. This strategy bypasses all metric and label name + // translation, passing them through unaltered. + // + // If omitted or null, UnderscoreEscapingWithSuffixes is used. TranslationStrategy *ExperimentalPrometheusMetricExporterTranslationStrategy `json:"translation_strategy,omitempty" yaml:"translation_strategy,omitempty" mapstructure:"translation_strategy,omitempty"` - // WithResourceConstantLabels corresponds to the JSON schema field - // "with_resource_constant_labels". + // Configure Prometheus Exporter to add resource attributes as metrics attributes, + // where the resource attribute keys match the patterns. WithResourceConstantLabels *IncludeExclude `json:"with_resource_constant_labels,omitempty" yaml:"with_resource_constant_labels,omitempty" mapstructure:"with_resource_constant_labels,omitempty"` - // WithoutScopeInfo corresponds to the JSON schema field "without_scope_info". - WithoutScopeInfo *bool `json:"without_scope_info,omitempty" yaml:"without_scope_info,omitempty" mapstructure:"without_scope_info,omitempty"` + // Configure Prometheus Exporter to produce metrics without a scope info metric. + // If omitted or null, false is used. + WithoutScopeInfo ExperimentalPrometheusMetricExporterWithoutScopeInfo `json:"without_scope_info,omitempty" yaml:"without_scope_info,omitempty" mapstructure:"without_scope_info,omitempty"` } +// Configure host. +// +// If omitted or null, localhost is used. +type ExperimentalPrometheusMetricExporterHost *string + +// Configure port. +// +// If omitted or null, 9464 is used. +type ExperimentalPrometheusMetricExporterPort *int + type ExperimentalPrometheusMetricExporterTranslationStrategy string const ExperimentalPrometheusMetricExporterTranslationStrategyNoTranslation ExperimentalPrometheusMetricExporterTranslationStrategy = "NoTranslation" @@ -290,25 +579,34 @@ const ExperimentalPrometheusMetricExporterTranslationStrategyNoUTF8EscapingWithS const ExperimentalPrometheusMetricExporterTranslationStrategyUnderscoreEscapingWithSuffixes ExperimentalPrometheusMetricExporterTranslationStrategy = "UnderscoreEscapingWithSuffixes" const ExperimentalPrometheusMetricExporterTranslationStrategyUnderscoreEscapingWithoutSuffixes ExperimentalPrometheusMetricExporterTranslationStrategy = "UnderscoreEscapingWithoutSuffixes" +// Configure Prometheus Exporter to produce metrics without a scope info metric. +// +// If omitted or null, false is used. +type ExperimentalPrometheusMetricExporterWithoutScopeInfo *bool + type ExperimentalResourceDetection struct { - // Attributes corresponds to the JSON schema field "attributes". + // Configure attributes provided by resource detectors. Attributes *IncludeExclude `json:"attributes,omitempty" yaml:"attributes,omitempty" mapstructure:"attributes,omitempty"` - // Detectors corresponds to the JSON schema field "detectors". + // Configure resource detectors. + // Resource detector names are dependent on the SDK language ecosystem. Please + // consult documentation for each respective language. + // If omitted or null, no resource detectors are enabled. Detectors []ExperimentalResourceDetector `json:"detectors,omitempty" yaml:"detectors,omitempty" mapstructure:"detectors,omitempty"` } type ExperimentalResourceDetector struct { - // Container corresponds to the JSON schema field "container". + // Enable the container resource detector, which populates container.* attributes. Container ExperimentalContainerResourceDetector `json:"container,omitempty" yaml:"container,omitempty" mapstructure:"container,omitempty"` - // Host corresponds to the JSON schema field "host". + // Enable the host resource detector, which populates host.* and os.* attributes. Host ExperimentalHostResourceDetector `json:"host,omitempty" yaml:"host,omitempty" mapstructure:"host,omitempty"` - // Process corresponds to the JSON schema field "process". + // Enable the process resource detector, which populates process.* attributes. Process ExperimentalProcessResourceDetector `json:"process,omitempty" yaml:"process,omitempty" mapstructure:"process,omitempty"` - // Service corresponds to the JSON schema field "service". + // Enable the service detector, which populates service.name based on the + // OTEL_SERVICE_NAME environment variable and service.instance.id. Service ExperimentalServiceResourceDetector `json:"service,omitempty" yaml:"service,omitempty" mapstructure:"service,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` @@ -317,34 +615,47 @@ type ExperimentalResourceDetector struct { type ExperimentalServiceResourceDetector map[string]interface{} type ExperimentalTracerConfig struct { - // Disabled corresponds to the JSON schema field "disabled". + // Configure if the tracer is enabled or not. Disabled *bool `json:"disabled,omitempty" yaml:"disabled,omitempty" mapstructure:"disabled,omitempty"` } type ExperimentalTracerConfigurator struct { - // DefaultConfig corresponds to the JSON schema field "default_config". + // Configure the default tracer config used there is no matching entry in + // .tracer_configurator/development.tracers. DefaultConfig *ExperimentalTracerConfig `json:"default_config,omitempty" yaml:"default_config,omitempty" mapstructure:"default_config,omitempty"` - // Tracers corresponds to the JSON schema field "tracers". + // Configure tracers. Tracers []ExperimentalTracerMatcherAndConfig `json:"tracers,omitempty" yaml:"tracers,omitempty" mapstructure:"tracers,omitempty"` } type ExperimentalTracerMatcherAndConfig struct { - // Config corresponds to the JSON schema field "config". + // The tracer config. Config *ExperimentalTracerConfig `json:"config,omitempty" yaml:"config,omitempty" mapstructure:"config,omitempty"` - // Name corresponds to the JSON schema field "name". + // Configure tracer names to match, evaluated as follows: + // + // * If the tracer name exactly matches. + // * If the tracer name matches the wildcard pattern, where '?' matches any + // single character and '*' matches any number of characters including none. Name *string `json:"name,omitempty" yaml:"name,omitempty" mapstructure:"name,omitempty"` } type ExplicitBucketHistogramAggregation struct { - // Boundaries corresponds to the JSON schema field "boundaries". + // Configure bucket boundaries. + // If omitted, [0, 5, 10, 25, 50, 75, 100, 250, 500, 750, 1000, 2500, 5000, 7500, + // 10000] is used. Boundaries []float64 `json:"boundaries,omitempty" yaml:"boundaries,omitempty" mapstructure:"boundaries,omitempty"` - // RecordMinMax corresponds to the JSON schema field "record_min_max". - RecordMinMax *bool `json:"record_min_max,omitempty" yaml:"record_min_max,omitempty" mapstructure:"record_min_max,omitempty"` + // Configure record min and max. + // If omitted or null, true is used. + RecordMinMax ExplicitBucketHistogramAggregationRecordMinMax `json:"record_min_max,omitempty" yaml:"record_min_max,omitempty" mapstructure:"record_min_max,omitempty"` } +// Configure record min and max. +// +// If omitted or null, true is used. +type ExplicitBucketHistogramAggregationRecordMinMax *bool + type ExporterDefaultHistogramAggregation string const ExporterDefaultHistogramAggregationBase2ExponentialBucketHistogram ExporterDefaultHistogramAggregation = "base2_exponential_bucket_histogram" @@ -356,11 +667,129 @@ const ExporterTemporalityPreferenceCumulative ExporterTemporalityPreference = "c const ExporterTemporalityPreferenceDelta ExporterTemporalityPreference = "delta" const ExporterTemporalityPreferenceLowMemory ExporterTemporalityPreference = "low_memory" +type GrpcTls struct { + // Configure certificate used to verify a server's TLS credentials. + // Absolute path to certificate file in PEM format. + // If omitted or null, system default certificate verification is used for secure + // connections. + CertificateFile GrpcTlsCertificateFile `json:"certificate_file,omitempty" yaml:"certificate_file,omitempty" mapstructure:"certificate_file,omitempty"` + + // Configure mTLS client certificate. + // Absolute path to client certificate file in PEM format. If set, .client_key + // must also be set. + // If omitted or null, mTLS is not used. + ClientCertificateFile GrpcTlsClientCertificateFile `json:"client_certificate_file,omitempty" yaml:"client_certificate_file,omitempty" mapstructure:"client_certificate_file,omitempty"` + + // Configure mTLS private client key. + // Absolute path to client key file in PEM format. If set, .client_certificate + // must also be set. + // If omitted or null, mTLS is not used. + ClientKeyFile GrpcTlsClientKeyFile `json:"client_key_file,omitempty" yaml:"client_key_file,omitempty" mapstructure:"client_key_file,omitempty"` + + // Configure client transport security for the exporter's connection. + // Only applicable when .endpoint is provided without http or https scheme. + // Implementations may choose to ignore .insecure. + // If omitted or null, false is used. + Insecure GrpcTlsInsecure `json:"insecure,omitempty" yaml:"insecure,omitempty" mapstructure:"insecure,omitempty"` +} + +// Configure certificate used to verify a server's TLS credentials. +// +// Absolute path to certificate file in PEM format. +// If omitted or null, system default certificate verification is used for secure +// +// connections. +type GrpcTlsCertificateFile *string + +// Configure mTLS client certificate. +// +// Absolute path to client certificate file in PEM format. If set, .client_key +// +// must also be set. +// +// If omitted or null, mTLS is not used. +type GrpcTlsClientCertificateFile *string + +// Configure mTLS private client key. +// +// Absolute path to client key file in PEM format. If set, .client_certificate +// +// must also be set. +// +// If omitted or null, mTLS is not used. +type GrpcTlsClientKeyFile *string + +// Configure client transport security for the exporter's connection. +// +// Only applicable when .endpoint is provided without http or https scheme. +// +// Implementations may choose to ignore .insecure. +// +// If omitted or null, false is used. +type GrpcTlsInsecure *bool + +type HttpTls struct { + // Configure certificate used to verify a server's TLS credentials. + // Absolute path to certificate file in PEM format. + // If omitted or null, system default certificate verification is used for secure + // connections. + CertificateFile HttpTlsCertificateFile `json:"certificate_file,omitempty" yaml:"certificate_file,omitempty" mapstructure:"certificate_file,omitempty"` + + // Configure mTLS client certificate. + // Absolute path to client certificate file in PEM format. If set, .client_key + // must also be set. + // If omitted or null, mTLS is not used. + ClientCertificateFile HttpTlsClientCertificateFile `json:"client_certificate_file,omitempty" yaml:"client_certificate_file,omitempty" mapstructure:"client_certificate_file,omitempty"` + + // Configure mTLS private client key. + // Absolute path to client key file in PEM format. If set, .client_certificate + // must also be set. + // If omitted or null, mTLS is not used. + ClientKeyFile HttpTlsClientKeyFile `json:"client_key_file,omitempty" yaml:"client_key_file,omitempty" mapstructure:"client_key_file,omitempty"` +} + +// Configure certificate used to verify a server's TLS credentials. +// +// Absolute path to certificate file in PEM format. +// If omitted or null, system default certificate verification is used for secure +// +// connections. +type HttpTlsCertificateFile *string + +// Configure mTLS client certificate. +// +// Absolute path to client certificate file in PEM format. If set, .client_key +// +// must also be set. +// +// If omitted or null, mTLS is not used. +type HttpTlsClientCertificateFile *string + +// Configure mTLS private client key. +// +// Absolute path to client key file in PEM format. If set, .client_certificate +// +// must also be set. +// +// If omitted or null, mTLS is not used. +type HttpTlsClientKeyFile *string + type IncludeExclude struct { - // Excluded corresponds to the JSON schema field "excluded". + // Configure list of value patterns to exclude. Applies after .included (i.e. + // excluded has higher priority than included). + // Values are evaluated to match as follows: + // * If the value exactly matches. + // * If the value matches the wildcard pattern, where '?' matches any single + // character and '*' matches any number of characters including none. + // If omitted, .included attributes are included. Excluded []string `json:"excluded,omitempty" yaml:"excluded,omitempty" mapstructure:"excluded,omitempty"` - // Included corresponds to the JSON schema field "included". + // Configure list of value patterns to include. + // Values are evaluated to match as follows: + // * If the value exactly matches. + // * If the value matches the wildcard pattern, where '?' matches any single + // character and '*' matches any number of characters including none. + // If omitted, all values are included. Included []string `json:"included,omitempty" yaml:"included,omitempty" mapstructure:"included,omitempty"` } @@ -375,212 +804,320 @@ const InstrumentTypeObservableUpDownCounter InstrumentType = "observable_up_down const InstrumentTypeUpDownCounter InstrumentType = "up_down_counter" type InstrumentationJson struct { - // Cpp corresponds to the JSON schema field "cpp". + // Configure C++ language-specific instrumentation libraries. Cpp ExperimentalLanguageSpecificInstrumentation `json:"cpp,omitempty" yaml:"cpp,omitempty" mapstructure:"cpp,omitempty"` - // Dotnet corresponds to the JSON schema field "dotnet". + // Configure .NET language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Dotnet ExperimentalLanguageSpecificInstrumentation `json:"dotnet,omitempty" yaml:"dotnet,omitempty" mapstructure:"dotnet,omitempty"` - // Erlang corresponds to the JSON schema field "erlang". + // Configure Erlang language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Erlang ExperimentalLanguageSpecificInstrumentation `json:"erlang,omitempty" yaml:"erlang,omitempty" mapstructure:"erlang,omitempty"` - // General corresponds to the JSON schema field "general". + // Configure general SemConv options that may apply to multiple languages and + // instrumentations. + // Instrumenation may merge general config options with the language specific + // configuration at .instrumentation.. General *ExperimentalGeneralInstrumentation `json:"general,omitempty" yaml:"general,omitempty" mapstructure:"general,omitempty"` - // Go corresponds to the JSON schema field "go". + // Configure Go language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Go ExperimentalLanguageSpecificInstrumentation `json:"go,omitempty" yaml:"go,omitempty" mapstructure:"go,omitempty"` - // Java corresponds to the JSON schema field "java". + // Configure Java language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Java ExperimentalLanguageSpecificInstrumentation `json:"java,omitempty" yaml:"java,omitempty" mapstructure:"java,omitempty"` - // Js corresponds to the JSON schema field "js". + // Configure JavaScript language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Js ExperimentalLanguageSpecificInstrumentation `json:"js,omitempty" yaml:"js,omitempty" mapstructure:"js,omitempty"` - // Php corresponds to the JSON schema field "php". + // Configure PHP language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Php ExperimentalLanguageSpecificInstrumentation `json:"php,omitempty" yaml:"php,omitempty" mapstructure:"php,omitempty"` - // Python corresponds to the JSON schema field "python". + // Configure Python language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Python ExperimentalLanguageSpecificInstrumentation `json:"python,omitempty" yaml:"python,omitempty" mapstructure:"python,omitempty"` - // Ruby corresponds to the JSON schema field "ruby". + // Configure Ruby language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Ruby ExperimentalLanguageSpecificInstrumentation `json:"ruby,omitempty" yaml:"ruby,omitempty" mapstructure:"ruby,omitempty"` - // Rust corresponds to the JSON schema field "rust". + // Configure Rust language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Rust ExperimentalLanguageSpecificInstrumentation `json:"rust,omitempty" yaml:"rust,omitempty" mapstructure:"rust,omitempty"` - // Swift corresponds to the JSON schema field "swift". + // Configure Swift language-specific instrumentation libraries. + // Each entry's key identifies a particular instrumentation library. The + // corresponding value configures it. Swift ExperimentalLanguageSpecificInstrumentation `json:"swift,omitempty" yaml:"swift,omitempty" mapstructure:"swift,omitempty"` } type JaegerPropagator map[string]interface{} -type JaegerRemoteSampler struct { - // Endpoint corresponds to the JSON schema field "endpoint". - Endpoint *string `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` - - // InitialSampler corresponds to the JSON schema field "initial_sampler". - InitialSampler *Sampler `json:"initial_sampler,omitempty" yaml:"initial_sampler,omitempty" mapstructure:"initial_sampler,omitempty"` - - // Interval corresponds to the JSON schema field "interval". - Interval *int `json:"interval,omitempty" yaml:"interval,omitempty" mapstructure:"interval,omitempty"` -} - type LastValueAggregation map[string]interface{} type LogRecordExporter struct { - // Console corresponds to the JSON schema field "console". + // Configure exporter to be console. Console ConsoleExporter `json:"console,omitempty" yaml:"console,omitempty" mapstructure:"console,omitempty"` - // OTLPFileDevelopment corresponds to the JSON schema field - // "otlp_file/development". + // Configure exporter to be OTLP with file transport. OTLPFileDevelopment *ExperimentalOTLPFileExporter `json:"otlp_file/development,omitempty" yaml:"otlp_file/development,omitempty" mapstructure:"otlp_file/development,omitempty"` - // OTLPGrpc corresponds to the JSON schema field "otlp_grpc". + // Configure exporter to be OTLP with gRPC transport. OTLPGrpc *OTLPGrpcExporter `json:"otlp_grpc,omitempty" yaml:"otlp_grpc,omitempty" mapstructure:"otlp_grpc,omitempty"` - // OTLPHttp corresponds to the JSON schema field "otlp_http". + // Configure exporter to be OTLP with HTTP transport. OTLPHttp *OTLPHttpExporter `json:"otlp_http,omitempty" yaml:"otlp_http,omitempty" mapstructure:"otlp_http,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` } type LogRecordLimits struct { - // AttributeCountLimit corresponds to the JSON schema field - // "attribute_count_limit". - AttributeCountLimit *int `json:"attribute_count_limit,omitempty" yaml:"attribute_count_limit,omitempty" mapstructure:"attribute_count_limit,omitempty"` - - // AttributeValueLengthLimit corresponds to the JSON schema field - // "attribute_value_length_limit". - AttributeValueLengthLimit *int `json:"attribute_value_length_limit,omitempty" yaml:"attribute_value_length_limit,omitempty" mapstructure:"attribute_value_length_limit,omitempty"` -} + // Configure max attribute count. Overrides + // .attribute_limits.attribute_count_limit. + // Value must be non-negative. + // If omitted or null, 128 is used. + AttributeCountLimit LogRecordLimitsAttributeCountLimit `json:"attribute_count_limit,omitempty" yaml:"attribute_count_limit,omitempty" mapstructure:"attribute_count_limit,omitempty"` + + // Configure max attribute value size. Overrides + // .attribute_limits.attribute_value_length_limit. + // Value must be non-negative. + // If omitted or null, there is no limit. + AttributeValueLengthLimit LogRecordLimitsAttributeValueLengthLimit `json:"attribute_value_length_limit,omitempty" yaml:"attribute_value_length_limit,omitempty" mapstructure:"attribute_value_length_limit,omitempty"` +} + +// Configure max attribute count. Overrides +// .attribute_limits.attribute_count_limit. +// +// Value must be non-negative. +// If omitted or null, 128 is used. +type LogRecordLimitsAttributeCountLimit *int + +// Configure max attribute value size. Overrides +// .attribute_limits.attribute_value_length_limit. +// +// Value must be non-negative. +// If omitted or null, there is no limit. +type LogRecordLimitsAttributeValueLengthLimit *int type LogRecordProcessor struct { - // Batch corresponds to the JSON schema field "batch". + // Configure a batch log record processor. Batch *BatchLogRecordProcessor `json:"batch,omitempty" yaml:"batch,omitempty" mapstructure:"batch,omitempty"` - // Simple corresponds to the JSON schema field "simple". + // Configure a simple log record processor. Simple *SimpleLogRecordProcessor `json:"simple,omitempty" yaml:"simple,omitempty" mapstructure:"simple,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` } type LoggerProviderJson struct { - // Limits corresponds to the JSON schema field "limits". + // Configure log record limits. See also attribute_limits. Limits *LogRecordLimits `json:"limits,omitempty" yaml:"limits,omitempty" mapstructure:"limits,omitempty"` - // LoggerConfiguratorDevelopment corresponds to the JSON schema field - // "logger_configurator/development". + // Configure loggers. LoggerConfiguratorDevelopment *ExperimentalLoggerConfigurator `json:"logger_configurator/development,omitempty" yaml:"logger_configurator/development,omitempty" mapstructure:"logger_configurator/development,omitempty"` - // Processors corresponds to the JSON schema field "processors". + // Configure log record processors. Processors []LogRecordProcessor `json:"processors" yaml:"processors" mapstructure:"processors"` } type MeterProviderJson struct { - // ExemplarFilter corresponds to the JSON schema field "exemplar_filter". + // Configure the exemplar filter. + // Values include: trace_based, always_on, always_off. For behavior of values see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#metrics-sdk-configuration. + // If omitted or null, trace_based is used. ExemplarFilter *ExemplarFilter `json:"exemplar_filter,omitempty" yaml:"exemplar_filter,omitempty" mapstructure:"exemplar_filter,omitempty"` - // MeterConfiguratorDevelopment corresponds to the JSON schema field - // "meter_configurator/development". + // Configure meters. MeterConfiguratorDevelopment *ExperimentalMeterConfigurator `json:"meter_configurator/development,omitempty" yaml:"meter_configurator/development,omitempty" mapstructure:"meter_configurator/development,omitempty"` - // Readers corresponds to the JSON schema field "readers". + // Configure metric readers. Readers []MetricReader `json:"readers" yaml:"readers" mapstructure:"readers"` - // Views corresponds to the JSON schema field "views". + // Configure views. + // Each view has a selector which determines the instrument(s) it applies to, and + // a configuration for the resulting stream(s). Views []View `json:"views,omitempty" yaml:"views,omitempty" mapstructure:"views,omitempty"` } type MetricProducer struct { - // Opencensus corresponds to the JSON schema field "opencensus". + // Configure metric producer to be opencensus. Opencensus OpenCensusMetricProducer `json:"opencensus,omitempty" yaml:"opencensus,omitempty" mapstructure:"opencensus,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` } type MetricReader struct { - // Periodic corresponds to the JSON schema field "periodic". + // Configure a periodic metric reader. Periodic *PeriodicMetricReader `json:"periodic,omitempty" yaml:"periodic,omitempty" mapstructure:"periodic,omitempty"` - // Pull corresponds to the JSON schema field "pull". + // Configure a pull based metric reader. Pull *PullMetricReader `json:"pull,omitempty" yaml:"pull,omitempty" mapstructure:"pull,omitempty"` } type NameStringValuePair struct { - // Name corresponds to the JSON schema field "name". + // The name of the pair. Name string `json:"name" yaml:"name" mapstructure:"name"` - // Value corresponds to the JSON schema field "value". - Value *string `json:"value" yaml:"value" mapstructure:"value"` + // The value of the pair. + Value NameStringValuePairValue `json:"value" yaml:"value" mapstructure:"value"` } -type OTLPGrpcExporter struct { - // CertificateFile corresponds to the JSON schema field "certificate_file". - CertificateFile *string `json:"certificate_file,omitempty" yaml:"certificate_file,omitempty" mapstructure:"certificate_file,omitempty"` - - // ClientCertificateFile corresponds to the JSON schema field - // "client_certificate_file". - ClientCertificateFile *string `json:"client_certificate_file,omitempty" yaml:"client_certificate_file,omitempty" mapstructure:"client_certificate_file,omitempty"` - - // ClientKeyFile corresponds to the JSON schema field "client_key_file". - ClientKeyFile *string `json:"client_key_file,omitempty" yaml:"client_key_file,omitempty" mapstructure:"client_key_file,omitempty"` - - // Compression corresponds to the JSON schema field "compression". - Compression *string `json:"compression,omitempty" yaml:"compression,omitempty" mapstructure:"compression,omitempty"` - - // Endpoint corresponds to the JSON schema field "endpoint". - Endpoint *string `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` +// The value of the pair. +type NameStringValuePairValue *string - // Headers corresponds to the JSON schema field "headers". +type OTLPGrpcExporter struct { + // Configure compression. + // Values include: gzip, none. Implementations may support other compression + // algorithms. + // If omitted or null, none is used. + Compression OTLPGrpcExporterCompression `json:"compression,omitempty" yaml:"compression,omitempty" mapstructure:"compression,omitempty"` + + // Configure endpoint. + // If omitted or null, http://localhost:4317 is used. + Endpoint OTLPGrpcExporterEndpoint `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` + + // Configure headers. Entries have higher priority than entries from + // .headers_list. + // If an entry's .value is null, the entry is ignored. Headers []NameStringValuePair `json:"headers,omitempty" yaml:"headers,omitempty" mapstructure:"headers,omitempty"` - // HeadersList corresponds to the JSON schema field "headers_list". - HeadersList *string `json:"headers_list,omitempty" yaml:"headers_list,omitempty" mapstructure:"headers_list,omitempty"` - - // Insecure corresponds to the JSON schema field "insecure". - Insecure *bool `json:"insecure,omitempty" yaml:"insecure,omitempty" mapstructure:"insecure,omitempty"` - - // Timeout corresponds to the JSON schema field "timeout". - Timeout *int `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` -} + // Configure headers. Entries have lower priority than entries from .headers. + // The value is a list of comma separated key-value pairs matching the format of + // OTEL_EXPORTER_OTLP_HEADERS. See + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md#configuration-options + // for details. + // If omitted or null, no headers are added. + HeadersList OTLPGrpcExporterHeadersList `json:"headers_list,omitempty" yaml:"headers_list,omitempty" mapstructure:"headers_list,omitempty"` + + // Configure max time (in milliseconds) to wait for each export. + // Value must be non-negative. A value of 0 indicates no limit (infinity). + // If omitted or null, 10000 is used. + Timeout OTLPGrpcExporterTimeout `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` + + // Configure TLS settings for the exporter. + Tls *GrpcTls `json:"tls,omitempty" yaml:"tls,omitempty" mapstructure:"tls,omitempty"` +} + +// Configure compression. +// +// Values include: gzip, none. Implementations may support other compression +// +// algorithms. +// +// If omitted or null, none is used. +type OTLPGrpcExporterCompression *string + +// Configure endpoint. +// +// If omitted or null, http://localhost:4317 is used. +type OTLPGrpcExporterEndpoint *string + +// Configure headers. Entries have lower priority than entries from .headers. +// +// The value is a list of comma separated key-value pairs matching the format of +// +// OTEL_EXPORTER_OTLP_HEADERS. See +// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md#configuration-options +// for details. +// +// If omitted or null, no headers are added. +type OTLPGrpcExporterHeadersList *string + +// Configure max time (in milliseconds) to wait for each export. +// +// Value must be non-negative. A value of 0 indicates no limit (infinity). +// If omitted or null, 10000 is used. +type OTLPGrpcExporterTimeout *int type OTLPGrpcMetricExporter struct { - // CertificateFile corresponds to the JSON schema field "certificate_file". - CertificateFile *string `json:"certificate_file,omitempty" yaml:"certificate_file,omitempty" mapstructure:"certificate_file,omitempty"` - - // ClientCertificateFile corresponds to the JSON schema field - // "client_certificate_file". - ClientCertificateFile *string `json:"client_certificate_file,omitempty" yaml:"client_certificate_file,omitempty" mapstructure:"client_certificate_file,omitempty"` - - // ClientKeyFile corresponds to the JSON schema field "client_key_file". - ClientKeyFile *string `json:"client_key_file,omitempty" yaml:"client_key_file,omitempty" mapstructure:"client_key_file,omitempty"` - - // Compression corresponds to the JSON schema field "compression". - Compression *string `json:"compression,omitempty" yaml:"compression,omitempty" mapstructure:"compression,omitempty"` - - // DefaultHistogramAggregation corresponds to the JSON schema field - // "default_histogram_aggregation". + // Configure compression. + // Values include: gzip, none. Implementations may support other compression + // algorithms. + // If omitted or null, none is used. + Compression OTLPGrpcMetricExporterCompression `json:"compression,omitempty" yaml:"compression,omitempty" mapstructure:"compression,omitempty"` + + // Configure default histogram aggregation. + // Values include: explicit_bucket_histogram, base2_exponential_bucket_histogram. + // For behavior of values, see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md. + // If omitted or null, explicit_bucket_histogram is used. DefaultHistogramAggregation *ExporterDefaultHistogramAggregation `json:"default_histogram_aggregation,omitempty" yaml:"default_histogram_aggregation,omitempty" mapstructure:"default_histogram_aggregation,omitempty"` - // Endpoint corresponds to the JSON schema field "endpoint". - Endpoint *string `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` + // Configure endpoint. + // If omitted or null, http://localhost:4317 is used. + Endpoint OTLPGrpcMetricExporterEndpoint `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` - // Headers corresponds to the JSON schema field "headers". + // Configure headers. Entries have higher priority than entries from + // .headers_list. + // If an entry's .value is null, the entry is ignored. Headers []NameStringValuePair `json:"headers,omitempty" yaml:"headers,omitempty" mapstructure:"headers,omitempty"` - // HeadersList corresponds to the JSON schema field "headers_list". - HeadersList *string `json:"headers_list,omitempty" yaml:"headers_list,omitempty" mapstructure:"headers_list,omitempty"` - - // Insecure corresponds to the JSON schema field "insecure". - Insecure *bool `json:"insecure,omitempty" yaml:"insecure,omitempty" mapstructure:"insecure,omitempty"` - - // TemporalityPreference corresponds to the JSON schema field - // "temporality_preference". + // Configure headers. Entries have lower priority than entries from .headers. + // The value is a list of comma separated key-value pairs matching the format of + // OTEL_EXPORTER_OTLP_HEADERS. See + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md#configuration-options + // for details. + // If omitted or null, no headers are added. + HeadersList OTLPGrpcMetricExporterHeadersList `json:"headers_list,omitempty" yaml:"headers_list,omitempty" mapstructure:"headers_list,omitempty"` + + // Configure temporality preference. + // Values include: cumulative, delta, low_memory. For behavior of values, see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md. + // If omitted or null, cumulative is used. TemporalityPreference *ExporterTemporalityPreference `json:"temporality_preference,omitempty" yaml:"temporality_preference,omitempty" mapstructure:"temporality_preference,omitempty"` - // Timeout corresponds to the JSON schema field "timeout". - Timeout *int `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` -} + // Configure max time (in milliseconds) to wait for each export. + // Value must be non-negative. A value of 0 indicates no limit (infinity). + // If omitted or null, 10000 is used. + Timeout OTLPGrpcMetricExporterTimeout `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` + + // Configure TLS settings for the exporter. + Tls *GrpcTls `json:"tls,omitempty" yaml:"tls,omitempty" mapstructure:"tls,omitempty"` +} + +// Configure compression. +// +// Values include: gzip, none. Implementations may support other compression +// +// algorithms. +// +// If omitted or null, none is used. +type OTLPGrpcMetricExporterCompression *string + +// Configure endpoint. +// +// If omitted or null, http://localhost:4317 is used. +type OTLPGrpcMetricExporterEndpoint *string + +// Configure headers. Entries have lower priority than entries from .headers. +// +// The value is a list of comma separated key-value pairs matching the format of +// +// OTEL_EXPORTER_OTLP_HEADERS. See +// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md#configuration-options +// for details. +// +// If omitted or null, no headers are added. +type OTLPGrpcMetricExporterHeadersList *string + +// Configure max time (in milliseconds) to wait for each export. +// +// Value must be non-negative. A value of 0 indicates no limit (infinity). +// If omitted or null, 10000 is used. +type OTLPGrpcMetricExporterTimeout *int type OTLPHttpEncoding string @@ -588,298 +1125,522 @@ const OTLPHttpEncodingJson OTLPHttpEncoding = "json" const OTLPHttpEncodingProtobuf OTLPHttpEncoding = "protobuf" type OTLPHttpExporter struct { - // CertificateFile corresponds to the JSON schema field "certificate_file". - CertificateFile *string `json:"certificate_file,omitempty" yaml:"certificate_file,omitempty" mapstructure:"certificate_file,omitempty"` - - // ClientCertificateFile corresponds to the JSON schema field - // "client_certificate_file". - ClientCertificateFile *string `json:"client_certificate_file,omitempty" yaml:"client_certificate_file,omitempty" mapstructure:"client_certificate_file,omitempty"` - - // ClientKeyFile corresponds to the JSON schema field "client_key_file". - ClientKeyFile *string `json:"client_key_file,omitempty" yaml:"client_key_file,omitempty" mapstructure:"client_key_file,omitempty"` - - // Compression corresponds to the JSON schema field "compression". - Compression *string `json:"compression,omitempty" yaml:"compression,omitempty" mapstructure:"compression,omitempty"` - - // Encoding corresponds to the JSON schema field "encoding". + // Configure compression. + // Values include: gzip, none. Implementations may support other compression + // algorithms. + // If omitted or null, none is used. + Compression OTLPHttpExporterCompression `json:"compression,omitempty" yaml:"compression,omitempty" mapstructure:"compression,omitempty"` + + // Configure the encoding used for messages. + // Values include: protobuf, json. Implementations may not support json. + // If omitted or null, protobuf is used. Encoding *OTLPHttpEncoding `json:"encoding,omitempty" yaml:"encoding,omitempty" mapstructure:"encoding,omitempty"` - // Endpoint corresponds to the JSON schema field "endpoint". - Endpoint *string `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` + // Configure endpoint, including the signal specific path. + // If omitted or null, the http://localhost:4318/v1/{signal} (where signal is + // 'traces', 'logs', or 'metrics') is used. + Endpoint OTLPHttpExporterEndpoint `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` - // Headers corresponds to the JSON schema field "headers". + // Configure headers. Entries have higher priority than entries from + // .headers_list. + // If an entry's .value is null, the entry is ignored. Headers []NameStringValuePair `json:"headers,omitempty" yaml:"headers,omitempty" mapstructure:"headers,omitempty"` - // HeadersList corresponds to the JSON schema field "headers_list". - HeadersList *string `json:"headers_list,omitempty" yaml:"headers_list,omitempty" mapstructure:"headers_list,omitempty"` - - // Timeout corresponds to the JSON schema field "timeout". - Timeout *int `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` -} + // Configure headers. Entries have lower priority than entries from .headers. + // The value is a list of comma separated key-value pairs matching the format of + // OTEL_EXPORTER_OTLP_HEADERS. See + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md#configuration-options + // for details. + // If omitted or null, no headers are added. + HeadersList OTLPHttpExporterHeadersList `json:"headers_list,omitempty" yaml:"headers_list,omitempty" mapstructure:"headers_list,omitempty"` + + // Configure max time (in milliseconds) to wait for each export. + // Value must be non-negative. A value of 0 indicates no limit (infinity). + // If omitted or null, 10000 is used. + Timeout OTLPHttpExporterTimeout `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` + + // Configure TLS settings for the exporter. + Tls *HttpTls `json:"tls,omitempty" yaml:"tls,omitempty" mapstructure:"tls,omitempty"` +} + +// Configure compression. +// +// Values include: gzip, none. Implementations may support other compression +// +// algorithms. +// +// If omitted or null, none is used. +type OTLPHttpExporterCompression *string + +// Configure endpoint, including the signal specific path. +// +// If omitted or null, the http://localhost:4318/v1/{signal} (where signal is +// +// 'traces', 'logs', or 'metrics') is used. +type OTLPHttpExporterEndpoint *string + +// Configure headers. Entries have lower priority than entries from .headers. +// +// The value is a list of comma separated key-value pairs matching the format of +// +// OTEL_EXPORTER_OTLP_HEADERS. See +// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md#configuration-options +// for details. +// +// If omitted or null, no headers are added. +type OTLPHttpExporterHeadersList *string + +// Configure max time (in milliseconds) to wait for each export. +// +// Value must be non-negative. A value of 0 indicates no limit (infinity). +// If omitted or null, 10000 is used. +type OTLPHttpExporterTimeout *int type OTLPHttpMetricExporter struct { - // CertificateFile corresponds to the JSON schema field "certificate_file". - CertificateFile *string `json:"certificate_file,omitempty" yaml:"certificate_file,omitempty" mapstructure:"certificate_file,omitempty"` - - // ClientCertificateFile corresponds to the JSON schema field - // "client_certificate_file". - ClientCertificateFile *string `json:"client_certificate_file,omitempty" yaml:"client_certificate_file,omitempty" mapstructure:"client_certificate_file,omitempty"` - - // ClientKeyFile corresponds to the JSON schema field "client_key_file". - ClientKeyFile *string `json:"client_key_file,omitempty" yaml:"client_key_file,omitempty" mapstructure:"client_key_file,omitempty"` - - // Compression corresponds to the JSON schema field "compression". - Compression *string `json:"compression,omitempty" yaml:"compression,omitempty" mapstructure:"compression,omitempty"` - - // DefaultHistogramAggregation corresponds to the JSON schema field - // "default_histogram_aggregation". + // Configure compression. + // Values include: gzip, none. Implementations may support other compression + // algorithms. + // If omitted or null, none is used. + Compression OTLPHttpMetricExporterCompression `json:"compression,omitempty" yaml:"compression,omitempty" mapstructure:"compression,omitempty"` + + // Configure default histogram aggregation. + // Values include: explicit_bucket_histogram, base2_exponential_bucket_histogram. + // For behavior of values, see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md. + // If omitted or null, explicit_bucket_histogram is used. DefaultHistogramAggregation *ExporterDefaultHistogramAggregation `json:"default_histogram_aggregation,omitempty" yaml:"default_histogram_aggregation,omitempty" mapstructure:"default_histogram_aggregation,omitempty"` - // Encoding corresponds to the JSON schema field "encoding". + // Configure the encoding used for messages. + // Values include: protobuf, json. Implementations may not support json. + // If omitted or null, protobuf is used. Encoding *OTLPHttpEncoding `json:"encoding,omitempty" yaml:"encoding,omitempty" mapstructure:"encoding,omitempty"` - // Endpoint corresponds to the JSON schema field "endpoint". - Endpoint *string `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` + // Configure endpoint, including the signal specific path. + // If omitted or null, the http://localhost:4318/v1/{signal} (where signal is + // 'traces', 'logs', or 'metrics') is used. + Endpoint OTLPHttpMetricExporterEndpoint `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` - // Headers corresponds to the JSON schema field "headers". + // Configure headers. Entries have higher priority than entries from + // .headers_list. + // If an entry's .value is null, the entry is ignored. Headers []NameStringValuePair `json:"headers,omitempty" yaml:"headers,omitempty" mapstructure:"headers,omitempty"` - // HeadersList corresponds to the JSON schema field "headers_list". - HeadersList *string `json:"headers_list,omitempty" yaml:"headers_list,omitempty" mapstructure:"headers_list,omitempty"` - - // TemporalityPreference corresponds to the JSON schema field - // "temporality_preference". + // Configure headers. Entries have lower priority than entries from .headers. + // The value is a list of comma separated key-value pairs matching the format of + // OTEL_EXPORTER_OTLP_HEADERS. See + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md#configuration-options + // for details. + // If omitted or null, no headers are added. + HeadersList OTLPHttpMetricExporterHeadersList `json:"headers_list,omitempty" yaml:"headers_list,omitempty" mapstructure:"headers_list,omitempty"` + + // Configure temporality preference. + // Values include: cumulative, delta, low_memory. For behavior of values, see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md. + // If omitted or null, cumulative is used. TemporalityPreference *ExporterTemporalityPreference `json:"temporality_preference,omitempty" yaml:"temporality_preference,omitempty" mapstructure:"temporality_preference,omitempty"` - // Timeout corresponds to the JSON schema field "timeout". - Timeout *int `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` -} + // Configure max time (in milliseconds) to wait for each export. + // Value must be non-negative. A value of 0 indicates no limit (infinity). + // If omitted or null, 10000 is used. + Timeout OTLPHttpMetricExporterTimeout `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` + + // Configure TLS settings for the exporter. + Tls *HttpTls `json:"tls,omitempty" yaml:"tls,omitempty" mapstructure:"tls,omitempty"` +} + +// Configure compression. +// +// Values include: gzip, none. Implementations may support other compression +// +// algorithms. +// +// If omitted or null, none is used. +type OTLPHttpMetricExporterCompression *string + +// Configure endpoint, including the signal specific path. +// +// If omitted or null, the http://localhost:4318/v1/{signal} (where signal is +// +// 'traces', 'logs', or 'metrics') is used. +type OTLPHttpMetricExporterEndpoint *string + +// Configure headers. Entries have lower priority than entries from .headers. +// +// The value is a list of comma separated key-value pairs matching the format of +// +// OTEL_EXPORTER_OTLP_HEADERS. See +// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md#configuration-options +// for details. +// +// If omitted or null, no headers are added. +type OTLPHttpMetricExporterHeadersList *string + +// Configure max time (in milliseconds) to wait for each export. +// +// Value must be non-negative. A value of 0 indicates no limit (infinity). +// If omitted or null, 10000 is used. +type OTLPHttpMetricExporterTimeout *int type OpenCensusMetricProducer map[string]interface{} type OpenTelemetryConfiguration struct { - // AttributeLimits corresponds to the JSON schema field "attribute_limits". + // Configure general attribute limits. See also tracer_provider.limits, + // logger_provider.limits. AttributeLimits *AttributeLimits `json:"attribute_limits,omitempty" yaml:"attribute_limits,omitempty" mapstructure:"attribute_limits,omitempty"` - // Disabled corresponds to the JSON schema field "disabled". - Disabled *bool `json:"disabled,omitempty" yaml:"disabled,omitempty" mapstructure:"disabled,omitempty"` + // Configure if the SDK is disabled or not. + // If omitted or null, false is used. + Disabled OpenTelemetryConfigurationDisabled `json:"disabled,omitempty" yaml:"disabled,omitempty" mapstructure:"disabled,omitempty"` - // FileFormat corresponds to the JSON schema field "file_format". + // The file format version. + // The yaml format is documented at + // https://github.com/open-telemetry/opentelemetry-configuration/tree/main/schema FileFormat string `json:"file_format" yaml:"file_format" mapstructure:"file_format"` - // InstrumentationDevelopment corresponds to the JSON schema field - // "instrumentation/development". - InstrumentationDevelopment OpenTelemetryConfigurationInstrumentationDevelopment `json:"instrumentation/development,omitempty" yaml:"instrumentation/development,omitempty" mapstructure:"instrumentation/development,omitempty"` + // Configure instrumentation. + InstrumentationDevelopment *InstrumentationJson `json:"instrumentation/development,omitempty" yaml:"instrumentation/development,omitempty" mapstructure:"instrumentation/development,omitempty"` - // LogLevel corresponds to the JSON schema field "log_level". - LogLevel *string `json:"log_level,omitempty" yaml:"log_level,omitempty" mapstructure:"log_level,omitempty"` + // Configure the log level of the internal logger used by the SDK. + // If omitted, info is used. + LogLevel OpenTelemetryConfigurationLogLevel `json:"log_level,omitempty" yaml:"log_level,omitempty" mapstructure:"log_level,omitempty"` - // LoggerProvider corresponds to the JSON schema field "logger_provider". - LoggerProvider OpenTelemetryConfigurationLoggerProvider `json:"logger_provider,omitempty" yaml:"logger_provider,omitempty" mapstructure:"logger_provider,omitempty"` + // Configure logger provider. + // If omitted, a noop logger provider is used. + LoggerProvider *LoggerProviderJson `json:"logger_provider,omitempty" yaml:"logger_provider,omitempty" mapstructure:"logger_provider,omitempty"` - // MeterProvider corresponds to the JSON schema field "meter_provider". - MeterProvider OpenTelemetryConfigurationMeterProvider `json:"meter_provider,omitempty" yaml:"meter_provider,omitempty" mapstructure:"meter_provider,omitempty"` + // Configure meter provider. + // If omitted, a noop meter provider is used. + MeterProvider *MeterProviderJson `json:"meter_provider,omitempty" yaml:"meter_provider,omitempty" mapstructure:"meter_provider,omitempty"` - // Propagator corresponds to the JSON schema field "propagator". - Propagator OpenTelemetryConfigurationPropagator `json:"propagator,omitempty" yaml:"propagator,omitempty" mapstructure:"propagator,omitempty"` + // Configure text map context propagators. + // If omitted, a noop propagator is used. + Propagator *PropagatorJson `json:"propagator,omitempty" yaml:"propagator,omitempty" mapstructure:"propagator,omitempty"` - // Resource corresponds to the JSON schema field "resource". - Resource OpenTelemetryConfigurationResource `json:"resource,omitempty" yaml:"resource,omitempty" mapstructure:"resource,omitempty"` + // Configure resource for all signals. + // If omitted, the default resource is used. + Resource *ResourceJson `json:"resource,omitempty" yaml:"resource,omitempty" mapstructure:"resource,omitempty"` - // TracerProvider corresponds to the JSON schema field "tracer_provider". - TracerProvider OpenTelemetryConfigurationTracerProvider `json:"tracer_provider,omitempty" yaml:"tracer_provider,omitempty" mapstructure:"tracer_provider,omitempty"` + // Configure tracer provider. + // If omitted, a noop tracer provider is used. + TracerProvider *TracerProviderJson `json:"tracer_provider,omitempty" yaml:"tracer_provider,omitempty" mapstructure:"tracer_provider,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` } -type OpenTelemetryConfigurationInstrumentationDevelopment interface{} +// Configure if the SDK is disabled or not. +// +// If omitted or null, false is used. +type OpenTelemetryConfigurationDisabled *bool -type OpenTelemetryConfigurationLoggerProvider interface{} - -type OpenTelemetryConfigurationMeterProvider interface{} - -type OpenTelemetryConfigurationPropagator interface{} - -type OpenTelemetryConfigurationResource interface{} - -type OpenTelemetryConfigurationTracerProvider interface{} +// Configure the log level of the internal logger used by the SDK. +// +// If omitted, info is used. +type OpenTelemetryConfigurationLogLevel *string type OpenTracingPropagator map[string]interface{} type ParentBasedSampler struct { - // LocalParentNotSampled corresponds to the JSON schema field - // "local_parent_not_sampled". + // Configure local_parent_not_sampled sampler. + // If omitted or null, always_off is used. LocalParentNotSampled *Sampler `json:"local_parent_not_sampled,omitempty" yaml:"local_parent_not_sampled,omitempty" mapstructure:"local_parent_not_sampled,omitempty"` - // LocalParentSampled corresponds to the JSON schema field "local_parent_sampled". + // Configure local_parent_sampled sampler. + // If omitted or null, always_on is used. LocalParentSampled *Sampler `json:"local_parent_sampled,omitempty" yaml:"local_parent_sampled,omitempty" mapstructure:"local_parent_sampled,omitempty"` - // RemoteParentNotSampled corresponds to the JSON schema field - // "remote_parent_not_sampled". + // Configure remote_parent_not_sampled sampler. + // If omitted or null, always_off is used. RemoteParentNotSampled *Sampler `json:"remote_parent_not_sampled,omitempty" yaml:"remote_parent_not_sampled,omitempty" mapstructure:"remote_parent_not_sampled,omitempty"` - // RemoteParentSampled corresponds to the JSON schema field - // "remote_parent_sampled". + // Configure remote_parent_sampled sampler. + // If omitted or null, always_on is used. RemoteParentSampled *Sampler `json:"remote_parent_sampled,omitempty" yaml:"remote_parent_sampled,omitempty" mapstructure:"remote_parent_sampled,omitempty"` - // Root corresponds to the JSON schema field "root". + // Configure root sampler. + // If omitted or null, always_on is used. Root *Sampler `json:"root,omitempty" yaml:"root,omitempty" mapstructure:"root,omitempty"` } type PeriodicMetricReader struct { - // CardinalityLimits corresponds to the JSON schema field "cardinality_limits". + // Configure cardinality limits. CardinalityLimits *CardinalityLimits `json:"cardinality_limits,omitempty" yaml:"cardinality_limits,omitempty" mapstructure:"cardinality_limits,omitempty"` - // Exporter corresponds to the JSON schema field "exporter". + // Configure exporter. Exporter PushMetricExporter `json:"exporter" yaml:"exporter" mapstructure:"exporter"` - // Interval corresponds to the JSON schema field "interval". - Interval *int `json:"interval,omitempty" yaml:"interval,omitempty" mapstructure:"interval,omitempty"` + // Configure delay interval (in milliseconds) between start of two consecutive + // exports. + // Value must be non-negative. + // If omitted or null, 60000 is used. + Interval PeriodicMetricReaderInterval `json:"interval,omitempty" yaml:"interval,omitempty" mapstructure:"interval,omitempty"` - // Producers corresponds to the JSON schema field "producers". + // Configure metric producers. Producers []MetricProducer `json:"producers,omitempty" yaml:"producers,omitempty" mapstructure:"producers,omitempty"` - // Timeout corresponds to the JSON schema field "timeout". - Timeout *int `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` + // Configure maximum allowed time (in milliseconds) to export data. + // Value must be non-negative. A value of 0 indicates no limit (infinity). + // If omitted or null, 30000 is used. + Timeout PeriodicMetricReaderTimeout `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` } +// Configure delay interval (in milliseconds) between start of two consecutive +// exports. +// +// Value must be non-negative. +// If omitted or null, 60000 is used. +type PeriodicMetricReaderInterval *int + +// Configure maximum allowed time (in milliseconds) to export data. +// +// Value must be non-negative. A value of 0 indicates no limit (infinity). +// If omitted or null, 30000 is used. +type PeriodicMetricReaderTimeout *int + type PropagatorJson struct { - // Composite corresponds to the JSON schema field "composite". + // Configure the propagators in the composite text map propagator. Entries from + // .composite_list are appended to the list here with duplicates filtered out. + // Built-in propagator keys include: tracecontext, baggage, b3, b3multi, jaeger, + // ottrace. Known third party keys include: xray. + // If the resolved list of propagators (from .composite and .composite_list) is + // empty, a noop propagator is used. Composite []TextMapPropagator `json:"composite,omitempty" yaml:"composite,omitempty" mapstructure:"composite,omitempty"` - // CompositeList corresponds to the JSON schema field "composite_list". - CompositeList *string `json:"composite_list,omitempty" yaml:"composite_list,omitempty" mapstructure:"composite_list,omitempty"` -} + // Configure the propagators in the composite text map propagator. Entries are + // appended to .composite with duplicates filtered out. + // The value is a comma separated list of propagator identifiers matching the + // format of OTEL_PROPAGATORS. See + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration + // for details. + // Built-in propagator identifiers include: tracecontext, baggage, b3, b3multi, + // jaeger, ottrace. Known third party identifiers include: xray. + // If the resolved list of propagators (from .composite and .composite_list) is + // empty, a noop propagator is used. + CompositeList PropagatorJsonCompositeList `json:"composite_list,omitempty" yaml:"composite_list,omitempty" mapstructure:"composite_list,omitempty"` +} + +// Configure the propagators in the composite text map propagator. Entries are +// appended to .composite with duplicates filtered out. +// +// The value is a comma separated list of propagator identifiers matching the +// +// format of OTEL_PROPAGATORS. See +// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration +// for details. +// +// Built-in propagator identifiers include: tracecontext, baggage, b3, b3multi, +// +// jaeger, ottrace. Known third party identifiers include: xray. +// +// If the resolved list of propagators (from .composite and .composite_list) is +// +// empty, a noop propagator is used. +type PropagatorJsonCompositeList *string type PullMetricExporter struct { - // PrometheusDevelopment corresponds to the JSON schema field - // "prometheus/development". + // Configure exporter to be prometheus. PrometheusDevelopment *ExperimentalPrometheusMetricExporter `json:"prometheus/development,omitempty" yaml:"prometheus/development,omitempty" mapstructure:"prometheus/development,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` } type PullMetricReader struct { - // CardinalityLimits corresponds to the JSON schema field "cardinality_limits". + // Configure cardinality limits. CardinalityLimits *CardinalityLimits `json:"cardinality_limits,omitempty" yaml:"cardinality_limits,omitempty" mapstructure:"cardinality_limits,omitempty"` - // Exporter corresponds to the JSON schema field "exporter". + // Configure exporter. Exporter PullMetricExporter `json:"exporter" yaml:"exporter" mapstructure:"exporter"` - // Producers corresponds to the JSON schema field "producers". + // Configure metric producers. Producers []MetricProducer `json:"producers,omitempty" yaml:"producers,omitempty" mapstructure:"producers,omitempty"` } type PushMetricExporter struct { - // Console corresponds to the JSON schema field "console". - Console ConsoleExporter `json:"console,omitempty" yaml:"console,omitempty" mapstructure:"console,omitempty"` + // Configure exporter to be console. + Console *ConsoleMetricExporter `json:"console,omitempty" yaml:"console,omitempty" mapstructure:"console,omitempty"` - // OTLPFileDevelopment corresponds to the JSON schema field - // "otlp_file/development". + // Configure exporter to be OTLP with file transport. OTLPFileDevelopment *ExperimentalOTLPFileMetricExporter `json:"otlp_file/development,omitempty" yaml:"otlp_file/development,omitempty" mapstructure:"otlp_file/development,omitempty"` - // OTLPGrpc corresponds to the JSON schema field "otlp_grpc". + // Configure exporter to be OTLP with gRPC transport. OTLPGrpc *OTLPGrpcMetricExporter `json:"otlp_grpc,omitempty" yaml:"otlp_grpc,omitempty" mapstructure:"otlp_grpc,omitempty"` - // OTLPHttp corresponds to the JSON schema field "otlp_http". + // Configure exporter to be OTLP with HTTP transport. OTLPHttp *OTLPHttpMetricExporter `json:"otlp_http,omitempty" yaml:"otlp_http,omitempty" mapstructure:"otlp_http,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` } type ResourceJson struct { - // Attributes corresponds to the JSON schema field "attributes". + // Configure resource attributes. Entries have higher priority than entries from + // .resource.attributes_list. Attributes []AttributeNameValue `json:"attributes,omitempty" yaml:"attributes,omitempty" mapstructure:"attributes,omitempty"` - // AttributesList corresponds to the JSON schema field "attributes_list". - AttributesList *string `json:"attributes_list,omitempty" yaml:"attributes_list,omitempty" mapstructure:"attributes_list,omitempty"` - - // DetectionDevelopment corresponds to the JSON schema field - // "detection/development". + // Configure resource attributes. Entries have lower priority than entries from + // .resource.attributes. + // The value is a list of comma separated key-value pairs matching the format of + // OTEL_RESOURCE_ATTRIBUTES. See + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration + // for details. + // If omitted or null, no resource attributes are added. + AttributesList ResourceJsonAttributesList `json:"attributes_list,omitempty" yaml:"attributes_list,omitempty" mapstructure:"attributes_list,omitempty"` + + // Configure resource detection. + // If omitted or null, resource detection is disabled. DetectionDevelopment *ExperimentalResourceDetection `json:"detection/development,omitempty" yaml:"detection/development,omitempty" mapstructure:"detection/development,omitempty"` - // SchemaUrl corresponds to the JSON schema field "schema_url". - SchemaUrl *string `json:"schema_url,omitempty" yaml:"schema_url,omitempty" mapstructure:"schema_url,omitempty"` + // Configure resource schema URL. + // If omitted or null, no schema URL is used. + SchemaUrl ResourceJsonSchemaUrl `json:"schema_url,omitempty" yaml:"schema_url,omitempty" mapstructure:"schema_url,omitempty"` } +// Configure resource attributes. Entries have lower priority than entries from +// .resource.attributes. +// +// The value is a list of comma separated key-value pairs matching the format of +// +// OTEL_RESOURCE_ATTRIBUTES. See +// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration +// for details. +// +// If omitted or null, no resource attributes are added. +type ResourceJsonAttributesList *string + +// Configure resource schema URL. +// +// If omitted or null, no schema URL is used. +type ResourceJsonSchemaUrl *string + type Sampler struct { - // AlwaysOff corresponds to the JSON schema field "always_off". + // Configure sampler to be always_off. AlwaysOff AlwaysOffSampler `json:"always_off,omitempty" yaml:"always_off,omitempty" mapstructure:"always_off,omitempty"` - // AlwaysOn corresponds to the JSON schema field "always_on". + // Configure sampler to be always_on. AlwaysOn AlwaysOnSampler `json:"always_on,omitempty" yaml:"always_on,omitempty" mapstructure:"always_on,omitempty"` - // JaegerRemote corresponds to the JSON schema field "jaeger_remote". - JaegerRemote *JaegerRemoteSampler `json:"jaeger_remote,omitempty" yaml:"jaeger_remote,omitempty" mapstructure:"jaeger_remote,omitempty"` + // Configure sampler to be composite. + CompositeDevelopment *ExperimentalComposableSampler `json:"composite/development,omitempty" yaml:"composite/development,omitempty" mapstructure:"composite/development,omitempty"` + + // TODO + JaegerRemoteDevelopment *ExperimentalJaegerRemoteSampler `json:"jaeger_remote/development,omitempty" yaml:"jaeger_remote/development,omitempty" mapstructure:"jaeger_remote/development,omitempty"` - // ParentBased corresponds to the JSON schema field "parent_based". + // Configure sampler to be parent_based. ParentBased *ParentBasedSampler `json:"parent_based,omitempty" yaml:"parent_based,omitempty" mapstructure:"parent_based,omitempty"` - // TraceIDRatioBased corresponds to the JSON schema field "trace_id_ratio_based". + // Configure sampler to be probability. + ProbabilityDevelopment *ExperimentalProbabilitySampler `json:"probability/development,omitempty" yaml:"probability/development,omitempty" mapstructure:"probability/development,omitempty"` + + // Configure sampler to be trace_id_ratio_based. TraceIDRatioBased *TraceIDRatioBasedSampler `json:"trace_id_ratio_based,omitempty" yaml:"trace_id_ratio_based,omitempty" mapstructure:"trace_id_ratio_based,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` } type SimpleLogRecordProcessor struct { - // Exporter corresponds to the JSON schema field "exporter". + // Configure exporter. Exporter LogRecordExporter `json:"exporter" yaml:"exporter" mapstructure:"exporter"` } type SimpleSpanProcessor struct { - // Exporter corresponds to the JSON schema field "exporter". + // Configure exporter. Exporter SpanExporter `json:"exporter" yaml:"exporter" mapstructure:"exporter"` } type SpanExporter struct { - // Console corresponds to the JSON schema field "console". + // Configure exporter to be console. Console ConsoleExporter `json:"console,omitempty" yaml:"console,omitempty" mapstructure:"console,omitempty"` - // OTLPFileDevelopment corresponds to the JSON schema field - // "otlp_file/development". + // Configure exporter to be OTLP with file transport. OTLPFileDevelopment *ExperimentalOTLPFileExporter `json:"otlp_file/development,omitempty" yaml:"otlp_file/development,omitempty" mapstructure:"otlp_file/development,omitempty"` - // OTLPGrpc corresponds to the JSON schema field "otlp_grpc". + // Configure exporter to be OTLP with gRPC transport. OTLPGrpc *OTLPGrpcExporter `json:"otlp_grpc,omitempty" yaml:"otlp_grpc,omitempty" mapstructure:"otlp_grpc,omitempty"` - // OTLPHttp corresponds to the JSON schema field "otlp_http". + // Configure exporter to be OTLP with HTTP transport. OTLPHttp *OTLPHttpExporter `json:"otlp_http,omitempty" yaml:"otlp_http,omitempty" mapstructure:"otlp_http,omitempty"` - // Zipkin corresponds to the JSON schema field "zipkin". + // Configure exporter to be zipkin. Zipkin *ZipkinSpanExporter `json:"zipkin,omitempty" yaml:"zipkin,omitempty" mapstructure:"zipkin,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` } type SpanLimits struct { - // AttributeCountLimit corresponds to the JSON schema field - // "attribute_count_limit". - AttributeCountLimit *int `json:"attribute_count_limit,omitempty" yaml:"attribute_count_limit,omitempty" mapstructure:"attribute_count_limit,omitempty"` - - // AttributeValueLengthLimit corresponds to the JSON schema field - // "attribute_value_length_limit". - AttributeValueLengthLimit *int `json:"attribute_value_length_limit,omitempty" yaml:"attribute_value_length_limit,omitempty" mapstructure:"attribute_value_length_limit,omitempty"` - - // EventAttributeCountLimit corresponds to the JSON schema field - // "event_attribute_count_limit". - EventAttributeCountLimit *int `json:"event_attribute_count_limit,omitempty" yaml:"event_attribute_count_limit,omitempty" mapstructure:"event_attribute_count_limit,omitempty"` - - // EventCountLimit corresponds to the JSON schema field "event_count_limit". - EventCountLimit *int `json:"event_count_limit,omitempty" yaml:"event_count_limit,omitempty" mapstructure:"event_count_limit,omitempty"` - - // LinkAttributeCountLimit corresponds to the JSON schema field - // "link_attribute_count_limit". - LinkAttributeCountLimit *int `json:"link_attribute_count_limit,omitempty" yaml:"link_attribute_count_limit,omitempty" mapstructure:"link_attribute_count_limit,omitempty"` - - // LinkCountLimit corresponds to the JSON schema field "link_count_limit". - LinkCountLimit *int `json:"link_count_limit,omitempty" yaml:"link_count_limit,omitempty" mapstructure:"link_count_limit,omitempty"` -} + // Configure max attribute count. Overrides + // .attribute_limits.attribute_count_limit. + // Value must be non-negative. + // If omitted or null, 128 is used. + AttributeCountLimit SpanLimitsAttributeCountLimit `json:"attribute_count_limit,omitempty" yaml:"attribute_count_limit,omitempty" mapstructure:"attribute_count_limit,omitempty"` + + // Configure max attribute value size. Overrides + // .attribute_limits.attribute_value_length_limit. + // Value must be non-negative. + // If omitted or null, there is no limit. + AttributeValueLengthLimit SpanLimitsAttributeValueLengthLimit `json:"attribute_value_length_limit,omitempty" yaml:"attribute_value_length_limit,omitempty" mapstructure:"attribute_value_length_limit,omitempty"` + + // Configure max attributes per span event. + // Value must be non-negative. + // If omitted or null, 128 is used. + EventAttributeCountLimit SpanLimitsEventAttributeCountLimit `json:"event_attribute_count_limit,omitempty" yaml:"event_attribute_count_limit,omitempty" mapstructure:"event_attribute_count_limit,omitempty"` + + // Configure max span event count. + // Value must be non-negative. + // If omitted or null, 128 is used. + EventCountLimit SpanLimitsEventCountLimit `json:"event_count_limit,omitempty" yaml:"event_count_limit,omitempty" mapstructure:"event_count_limit,omitempty"` + + // Configure max attributes per span link. + // Value must be non-negative. + // If omitted or null, 128 is used. + LinkAttributeCountLimit SpanLimitsLinkAttributeCountLimit `json:"link_attribute_count_limit,omitempty" yaml:"link_attribute_count_limit,omitempty" mapstructure:"link_attribute_count_limit,omitempty"` + + // Configure max span link count. + // Value must be non-negative. + // If omitted or null, 128 is used. + LinkCountLimit SpanLimitsLinkCountLimit `json:"link_count_limit,omitempty" yaml:"link_count_limit,omitempty" mapstructure:"link_count_limit,omitempty"` +} + +// Configure max attribute count. Overrides +// .attribute_limits.attribute_count_limit. +// +// Value must be non-negative. +// If omitted or null, 128 is used. +type SpanLimitsAttributeCountLimit *int + +// Configure max attribute value size. Overrides +// .attribute_limits.attribute_value_length_limit. +// +// Value must be non-negative. +// If omitted or null, there is no limit. +type SpanLimitsAttributeValueLengthLimit *int + +// Configure max attributes per span event. +// +// Value must be non-negative. +// If omitted or null, 128 is used. +type SpanLimitsEventAttributeCountLimit *int + +// Configure max span event count. +// +// Value must be non-negative. +// If omitted or null, 128 is used. +type SpanLimitsEventCountLimit *int + +// Configure max attributes per span link. +// +// Value must be non-negative. +// If omitted or null, 128 is used. +type SpanLimitsLinkAttributeCountLimit *int + +// Configure max span link count. +// +// Value must be non-negative. +// If omitted or null, 128 is used. +type SpanLimitsLinkCountLimit *int type SpanProcessor struct { - // Batch corresponds to the JSON schema field "batch". + // Configure a batch span processor. Batch *BatchSpanProcessor `json:"batch,omitempty" yaml:"batch,omitempty" mapstructure:"batch,omitempty"` - // Simple corresponds to the JSON schema field "simple". + // Configure a simple span processor. Simple *SimpleSpanProcessor `json:"simple,omitempty" yaml:"simple,omitempty" mapstructure:"simple,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` @@ -888,22 +1649,22 @@ type SpanProcessor struct { type SumAggregation map[string]interface{} type TextMapPropagator struct { - // B3 corresponds to the JSON schema field "b3". + // Include the zipkin b3 propagator. B3 B3Propagator `json:"b3,omitempty" yaml:"b3,omitempty" mapstructure:"b3,omitempty"` - // B3Multi corresponds to the JSON schema field "b3multi". + // Include the zipkin b3 multi propagator. B3Multi B3MultiPropagator `json:"b3multi,omitempty" yaml:"b3multi,omitempty" mapstructure:"b3multi,omitempty"` - // Baggage corresponds to the JSON schema field "baggage". + // Include the w3c baggage propagator. Baggage BaggagePropagator `json:"baggage,omitempty" yaml:"baggage,omitempty" mapstructure:"baggage,omitempty"` - // Jaeger corresponds to the JSON schema field "jaeger". + // Include the jaeger propagator. Jaeger JaegerPropagator `json:"jaeger,omitempty" yaml:"jaeger,omitempty" mapstructure:"jaeger,omitempty"` - // Ottrace corresponds to the JSON schema field "ottrace". + // Include the opentracing propagator. Ottrace OpenTracingPropagator `json:"ottrace,omitempty" yaml:"ottrace,omitempty" mapstructure:"ottrace,omitempty"` - // Tracecontext corresponds to the JSON schema field "tracecontext". + // Include the w3c trace context propagator. Tracecontext TraceContextPropagator `json:"tracecontext,omitempty" yaml:"tracecontext,omitempty" mapstructure:"tracecontext,omitempty"` AdditionalProperties interface{} `mapstructure:",remain"` @@ -912,75 +1673,151 @@ type TextMapPropagator struct { type TraceContextPropagator map[string]interface{} type TraceIDRatioBasedSampler struct { - // Ratio corresponds to the JSON schema field "ratio". - Ratio *float64 `json:"ratio,omitempty" yaml:"ratio,omitempty" mapstructure:"ratio,omitempty"` + // Configure trace_id_ratio. + // If omitted or null, 1.0 is used. + Ratio TraceIDRatioBasedSamplerRatio `json:"ratio,omitempty" yaml:"ratio,omitempty" mapstructure:"ratio,omitempty"` } +// Configure trace_id_ratio. +// +// If omitted or null, 1.0 is used. +type TraceIDRatioBasedSamplerRatio *float64 + type TracerProviderJson struct { - // Limits corresponds to the JSON schema field "limits". + // Configure span limits. See also attribute_limits. Limits *SpanLimits `json:"limits,omitempty" yaml:"limits,omitempty" mapstructure:"limits,omitempty"` - // Processors corresponds to the JSON schema field "processors". + // Configure span processors. Processors []SpanProcessor `json:"processors" yaml:"processors" mapstructure:"processors"` - // Sampler corresponds to the JSON schema field "sampler". + // Configure the sampler. + // If omitted, parent based sampler with a root of always_on is used. Sampler *Sampler `json:"sampler,omitempty" yaml:"sampler,omitempty" mapstructure:"sampler,omitempty"` - // TracerConfiguratorDevelopment corresponds to the JSON schema field - // "tracer_configurator/development". + // Configure tracers. TracerConfiguratorDevelopment *ExperimentalTracerConfigurator `json:"tracer_configurator/development,omitempty" yaml:"tracer_configurator/development,omitempty" mapstructure:"tracer_configurator/development,omitempty"` } type View struct { - // Selector corresponds to the JSON schema field "selector". - Selector *ViewSelector `json:"selector,omitempty" yaml:"selector,omitempty" mapstructure:"selector,omitempty"` + // Configure view selector. + // Selection criteria is additive as described in + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk.md#instrument-selection-criteria. + Selector ViewSelector `json:"selector" yaml:"selector" mapstructure:"selector"` - // Stream corresponds to the JSON schema field "stream". - Stream *ViewStream `json:"stream,omitempty" yaml:"stream,omitempty" mapstructure:"stream,omitempty"` + // Configure view stream. + Stream ViewStream `json:"stream" yaml:"stream" mapstructure:"stream"` } type ViewSelector struct { - // InstrumentName corresponds to the JSON schema field "instrument_name". - InstrumentName *string `json:"instrument_name,omitempty" yaml:"instrument_name,omitempty" mapstructure:"instrument_name,omitempty"` - - // InstrumentType corresponds to the JSON schema field "instrument_type". + // Configure instrument name selection criteria. + // If omitted or null, all instrument names match. + InstrumentName ViewSelectorInstrumentName `json:"instrument_name,omitempty" yaml:"instrument_name,omitempty" mapstructure:"instrument_name,omitempty"` + + // Configure instrument type selection criteria. + // Values include: counter, gauge, histogram, observable_counter, + // observable_gauge, observable_up_down_counter, up_down_counter. + // If omitted or null, all instrument types match. InstrumentType *InstrumentType `json:"instrument_type,omitempty" yaml:"instrument_type,omitempty" mapstructure:"instrument_type,omitempty"` - // MeterName corresponds to the JSON schema field "meter_name". - MeterName *string `json:"meter_name,omitempty" yaml:"meter_name,omitempty" mapstructure:"meter_name,omitempty"` + // Configure meter name selection criteria. + // If omitted or null, all meter names match. + MeterName ViewSelectorMeterName `json:"meter_name,omitempty" yaml:"meter_name,omitempty" mapstructure:"meter_name,omitempty"` - // MeterSchemaUrl corresponds to the JSON schema field "meter_schema_url". - MeterSchemaUrl *string `json:"meter_schema_url,omitempty" yaml:"meter_schema_url,omitempty" mapstructure:"meter_schema_url,omitempty"` + // Configure meter schema url selection criteria. + // If omitted or null, all meter schema URLs match. + MeterSchemaUrl ViewSelectorMeterSchemaUrl `json:"meter_schema_url,omitempty" yaml:"meter_schema_url,omitempty" mapstructure:"meter_schema_url,omitempty"` - // MeterVersion corresponds to the JSON schema field "meter_version". - MeterVersion *string `json:"meter_version,omitempty" yaml:"meter_version,omitempty" mapstructure:"meter_version,omitempty"` + // Configure meter version selection criteria. + // If omitted or null, all meter versions match. + MeterVersion ViewSelectorMeterVersion `json:"meter_version,omitempty" yaml:"meter_version,omitempty" mapstructure:"meter_version,omitempty"` - // Unit corresponds to the JSON schema field "unit". - Unit *string `json:"unit,omitempty" yaml:"unit,omitempty" mapstructure:"unit,omitempty"` + // Configure the instrument unit selection criteria. + // If omitted or null, all instrument units match. + Unit ViewSelectorUnit `json:"unit,omitempty" yaml:"unit,omitempty" mapstructure:"unit,omitempty"` } +// Configure instrument name selection criteria. +// +// If omitted or null, all instrument names match. +type ViewSelectorInstrumentName *string + +// Configure meter name selection criteria. +// +// If omitted or null, all meter names match. +type ViewSelectorMeterName *string + +// Configure meter schema url selection criteria. +// +// If omitted or null, all meter schema URLs match. +type ViewSelectorMeterSchemaUrl *string + +// Configure meter version selection criteria. +// +// If omitted or null, all meter versions match. +type ViewSelectorMeterVersion *string + +// Configure the instrument unit selection criteria. +// +// If omitted or null, all instrument units match. +type ViewSelectorUnit *string + type ViewStream struct { - // Aggregation corresponds to the JSON schema field "aggregation". + // Configure aggregation of the resulting stream(s). + // Values include: default, drop, explicit_bucket_histogram, + // base2_exponential_bucket_histogram, last_value, sum. For behavior of values see + // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk.md#aggregation. + // If omitted, default is used. Aggregation *Aggregation `json:"aggregation,omitempty" yaml:"aggregation,omitempty" mapstructure:"aggregation,omitempty"` - // AggregationCardinalityLimit corresponds to the JSON schema field - // "aggregation_cardinality_limit". - AggregationCardinalityLimit *int `json:"aggregation_cardinality_limit,omitempty" yaml:"aggregation_cardinality_limit,omitempty" mapstructure:"aggregation_cardinality_limit,omitempty"` + // Configure the aggregation cardinality limit. + // If omitted or null, the metric reader's default cardinality limit is used. + AggregationCardinalityLimit ViewStreamAggregationCardinalityLimit `json:"aggregation_cardinality_limit,omitempty" yaml:"aggregation_cardinality_limit,omitempty" mapstructure:"aggregation_cardinality_limit,omitempty"` - // AttributeKeys corresponds to the JSON schema field "attribute_keys". + // Configure attribute keys retained in the resulting stream(s). AttributeKeys *IncludeExclude `json:"attribute_keys,omitempty" yaml:"attribute_keys,omitempty" mapstructure:"attribute_keys,omitempty"` - // Description corresponds to the JSON schema field "description". - Description *string `json:"description,omitempty" yaml:"description,omitempty" mapstructure:"description,omitempty"` + // Configure metric description of the resulting stream(s). + // If omitted or null, the instrument's origin description is used. + Description ViewStreamDescription `json:"description,omitempty" yaml:"description,omitempty" mapstructure:"description,omitempty"` - // Name corresponds to the JSON schema field "name". - Name *string `json:"name,omitempty" yaml:"name,omitempty" mapstructure:"name,omitempty"` + // Configure metric name of the resulting stream(s). + // If omitted or null, the instrument's original name is used. + Name ViewStreamName `json:"name,omitempty" yaml:"name,omitempty" mapstructure:"name,omitempty"` } -type ZipkinSpanExporter struct { - // Endpoint corresponds to the JSON schema field "endpoint". - Endpoint *string `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` +// Configure the aggregation cardinality limit. +// +// If omitted or null, the metric reader's default cardinality limit is used. +type ViewStreamAggregationCardinalityLimit *int - // Timeout corresponds to the JSON schema field "timeout". - Timeout *int `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` -} +// Configure metric description of the resulting stream(s). +// +// If omitted or null, the instrument's origin description is used. +type ViewStreamDescription *string + +// Configure metric name of the resulting stream(s). +// +// If omitted or null, the instrument's original name is used. +type ViewStreamName *string + +type ZipkinSpanExporter struct { + // Configure endpoint. + // If omitted or null, http://localhost:9411/api/v2/spans is used. + Endpoint ZipkinSpanExporterEndpoint `json:"endpoint,omitempty" yaml:"endpoint,omitempty" mapstructure:"endpoint,omitempty"` + + // Configure max time (in milliseconds) to wait for each export. + // Value must be non-negative. A value of 0 indicates indefinite. + // If omitted or null, 10000 is used. + Timeout ZipkinSpanExporterTimeout `json:"timeout,omitempty" yaml:"timeout,omitempty" mapstructure:"timeout,omitempty"` +} + +// Configure endpoint. +// +// If omitted or null, http://localhost:9411/api/v2/spans is used. +type ZipkinSpanExporterEndpoint *string + +// Configure max time (in milliseconds) to wait for each export. +// +// Value must be non-negative. A value of 0 indicates indefinite. +// If omitted or null, 10000 is used. +type ZipkinSpanExporterTimeout *int