Skip to content

Commit

Permalink
Add .meter_provider.exemplar_filter property (open-telemetry#131)
Browse files Browse the repository at this point in the history
* Add .meter_provider.exemplar_filter property

* Fix build
  • Loading branch information
jack-berg authored Oct 10, 2024
1 parent 844869c commit cc623f7
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 1 deletion.
2 changes: 2 additions & 0 deletions examples/kitchen-sink.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@ meter_provider:
# Configure list of attribute keys to exclude from the resulting stream(s). Applies after .attribute_keys.included (i.e. excluded has higher priority than included).
excluded:
- key3
# Configure the exemplar filter. Known values include: trace_based, always_on, always_off.
exemplar_filter: trace_based

# Configure text map context propagators.
propagator:
Expand Down
2 changes: 2 additions & 0 deletions examples/sdk-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,8 @@ meter_provider:
temporality_preference: cumulative
# Configure default histogram aggregation.
default_histogram_aggregation: explicit_bucket_histogram
# Configure the exemplar filter. Known values include: trace_based, always_on, always_off.
exemplar_filter: trace_based

# Configure logger provider.
logger_provider:
Expand Down
3 changes: 2 additions & 1 deletion examples/sdk-migration-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
# - OTEL_TRACES_EXPORTER
# - OTEL_METRICS_EXPORTER
# - OTEL_LOGS_EXPORTER
# - OTEL_METRICS_EXEMPLAR_FILTER
# - OTEL_EXPORTER_OTLP_PROTOCOL
# - OTEL_EXPORTER_OTLP_ENDPOINT
# - OTEL_EXPORTER_OTLP_INSECURE, OTEL_EXPORTER_OTLP_{SIGNAL}_INSECURE
Expand Down Expand Up @@ -177,6 +176,8 @@ meter_provider:
temporality_preference: ${OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE:-cumulative}
# Configure default histogram aggregation.
default_histogram_aggregation: ${OTEL_EXPORTER_OTLP_METRICS_DEFAULT_HISTOGRAM_AGGREGATION:-explicit_bucket_histogram}
# Configure the exemplar filter. Known values include: trace_based, always_on, always_off.
exemplar_filter: ${OTEL_METRICS_EXEMPLAR_FILTER:-trace_based}

# Configure logger provider.
logger_provider:
Expand Down
8 changes: 8 additions & 0 deletions schema/meter_provider.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,14 @@
"items": {
"$ref": "#/$defs/View"
}
},
"exemplar_filter": {
"type": ["string", "null"],
"enum": [
"always_on",
"always_off",
"trace_based"
]
}
},
"$defs": {
Expand Down
1 change: 1 addition & 0 deletions schema/type_descriptions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,7 @@
property_descriptions:
readers: Configure metric readers.
views: Configure views. Each view has a selector which determines the instrument(s) it applies to, and a configuration for the resulting stream(s).
exemplar_filter: "Configure the exemplar filter. Known values include: trace_based, always_on, always_off."
path_patterns:
- .meter_provider

Expand Down

0 comments on commit cc623f7

Please sign in to comment.