Skip to content

Commit

Permalink
Add OTEL_TRACE_SAMPLER. (open-telemetry#1136)
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosalberto authored Oct 28, 2020
1 parent 33e1533 commit 88d139a
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ New:
([#1074](https://github.com/open-telemetry/opentelemetry-specification/pull/1074))
- Add semantic conventions for system metrics
([#937](https://github.com/open-telemetry/opentelemetry-specification/pull/937))
- Add OTEL_TRACE_SAMPLER env variable definition
([#1136](https://github.com/open-telemetry/opentelemetry-specification/pull/1136/))

Updates:

Expand Down
1 change: 1 addition & 0 deletions spec-compliance-matrix.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ status of the feature is not known.
|OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT | | | | | | | | | | |
|OTEL_SPAN_EVENT_COUNT_LIMIT | | | | | | | | | | |
|OTEL_SPAN_LINK_COUNT_LIMIT | | | | | | | | | | |
|OTEL_TRACE_SAMPLER | | | | | | | | | | |

## Exporters

Expand Down
10 changes: 10 additions & 0 deletions specification/sdk-environment-variables.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,20 @@ The goal of this specification is to unify the environment variable names betwee
| OTEL_RESOURCE_ATTRIBUTES | Key-value pairs to be used as resource attributes | | See [Resource SDK](./resource/sdk.md#specifying-resource-information-via-an-environment-variable) for more details. |
| OTEL_LOG_LEVEL | Log level used by the SDK logger | "info" | |
| OTEL_PROPAGATORS | Propagators to be used as a comma separated list | "tracecontext,baggage" | Values MUST be deduplicated in order to register a `Propagator` only once. Unrecognized values MUST generate a warning and be gracefully ignored. |
| OTEL_TRACE_SAMPLER | Sampler to be used for traces | "parentbased_always_on" | See [Sampling](./trace/sdk.md#sampling) |

Known values for OTEL_PROPAGATORS are: "tracecontext", "baggage", "b3", "jaeger".
Additional values can be specified in the respective SDK's documentation, in case third party `Propagator`s are supported, such as "xray" or "ottracer".

Known values for `OTEL_TRACE_SAMPLER` are:

- `"always_on"`: `AlwaysOnSampler`
- `"always_off"`: `AlwaysOffSampler`
- `"traceidratio"`: `TraceIdRatioBased`
- `"parentbased_always_on"`: `ParentBased(root=AlwaysOnSampler)`
- `"parentbased_always_off"`: `ParentBased(root=AlwaysOffSampler)`
- `"parentbased_traceidratio"`: `ParentBased(root=TraceIdRatioBased)`

## Batch Span Processor

| Name | Description | Default | Notes |
Expand Down

0 comments on commit 88d139a

Please sign in to comment.