Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/trace/customizing-the-sdk/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -363,8 +363,8 @@ var tracerProvider = Sdk.CreateTracerProviderBuilder()
.Build();
```

It is also possible to configure the sampler by using the following
environmental variables:
If using `1.8.0-rc.1` or newer it is also possible to configure the sampler by
using the following environmental variables:

| Environment variable | Description |
| -------------------------- | -------------------------------------------------- |
Expand Down
7 changes: 1 addition & 6 deletions src/OpenTelemetry/Trace/TracerProviderSdk.cs
Original file line number Diff line number Diff line change
Expand Up @@ -407,12 +407,7 @@ protected override void Dispose(bool disposing)

private static Sampler GetSampler(IConfiguration configuration, Sampler? stateSampler)
{
Sampler? sampler = null;

if (stateSampler != null)
{
sampler = stateSampler;
}
var sampler = stateSampler;

if (configuration.TryGetStringValue(TracesSamplerConfigKey, out var configValue))
{
Expand Down