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
2 changes: 1 addition & 1 deletion develop-docs/sdk/telemetry/traces/opentelemetry.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ When Sentry performance monitoring was initially introduced, OpenTelemetry was i

To transform OpenTelemetry SDK data to Sentry data, we rely on the [OpenTelemetry SpanProcessor](https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/sdk.md#span-processor) and [OpenTelemetry Propagator API](https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/context/api-propagators.md).

We want users to use Sentry for sampling functionality, so users should use OpenTelemetry's default sampler and sample through Sentry's `trace_sampler` and `traces_sample_rate` options.
We want users to use Sentry for sampling functionality, so users should use OpenTelemetry's default sampler and sample through Sentry's `traces_sampler` and `traces_sample_rate` options.

To be classified as fully supporting OpenTelemetry the OpenTelemetry instrumentation must support the following features:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ For more granular control, you provide a `tracesSampler` function. This approach
- Make sampling decisions based on transaction data
- Control the inheritance of sampling decisions in distributed traces

<PlatformContent includePath="/tracing/trace-sampler" />
<PlatformContent includePath="/tracing/traces-sampler" />

### The Sampling Context Object

Expand All @@ -53,7 +53,7 @@ interface SamplingContext {
}
```

### Trace Sampler Examples
### Traces Sampler Examples

1. Prioritizing Critical User Flows

Expand Down
6 changes: 3 additions & 3 deletions docs/platforms/python/tracing/configure-sampling/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ sidebar_order: 40

If you find that Sentry's tracing functionality is generating too much data, for example, if you notice your spans quota is quickly being exhausted, you can choose to sample your traces.

Effective sampling is key to getting the most value from Sentry's performance monitoring while minimizing overhead. The Python SDK provides two ways to control the sampling rate. You can review the options and [examples](#trace-sampler-examples) below.
Effective sampling is key to getting the most value from Sentry's performance monitoring while minimizing overhead. The Python SDK provides two ways to control the sampling rate. You can review the options and [examples](#traces-sampler-examples) below.

## Sampling Configuration Options

Expand Down Expand Up @@ -39,9 +39,9 @@ In distributed systems, implementing inheritance logic when trace information is
<PlatformContent includePath="/performance/traces-sampler-as-sampler" />

<details>
<summary className="text-xl font-semibold">Trace Sampler Examples</summary>
<summary className="text-xl font-semibold">Traces Sampler Examples</summary>

#### Trace Sampler Examples
#### Traces Sampler Examples

1. Prioritizing Critical User Flows

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,24 @@ Sentry.init({
tracesSampler: (samplingContext) => {
// Access transaction details from the sampling context
const { name, attributes, inheritOrSampleWith } = samplingContext;

// Skip health checks entirely
if (name.includes('healthcheck')) {
return 0;
}

// Capture all auth-related transactions
if (name.includes('auth')) {
return 1;
}

// Sample only 1% of comment-related transactions
if (name.includes('comment')) {
return 0.01;
}

// For everything else, inherit parent sampling decision or use 0.5
return inheritOrSampleWith(0.5);
}
});
```
```
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,24 @@ Sentry.init({
tracesSampler: (samplingContext) => {
// Access transaction details from the sampling context
const { name, attributes, inheritOrSampleWith } = samplingContext;

// Skip health checks entirely
if (name.includes('healthcheck')) {
return 0;
}

// Capture all auth-related transactions
if (name.includes('auth')) {
return 1;
}

// Sample only 1% of comment-related transactions
if (name.includes('comment')) {
return 0.01;
}

// For everything else, inherit parent sampling decision or use 0.5
return inheritOrSampleWith(0.5);
}
});
```
```
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,24 @@ Sentry.init({
tracesSampler: (samplingContext) => {
// Access transaction details from the sampling context
const { name, attributes, inheritOrSampleWith } = samplingContext;

// Skip health checks entirely
if (name.includes('healthcheck')) {
return 0;
}

// Capture all auth-related transactions
if (name.includes('auth')) {
return 1;
}

// Sample only 1% of comment-related transactions
if (name.includes('comment')) {
return 0.01;
}

// For everything else, inherit parent sampling decision or use 0.5
return inheritOrSampleWith(0.5);
}
});
```
```
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,24 @@ Sentry.init({
tracesSampler: (samplingContext) => {
// Access transaction details from the sampling context
const { name, attributes, inheritOrSampleWith } = samplingContext;

// Skip health checks entirely
if (name.includes('healthcheck')) {
return 0;
}

// Capture all auth-related transactions
if (name.includes('auth')) {
return 1;
}

// Sample only 1% of comment-related transactions
if (name.includes('comment')) {
return 0.01;
}

// For everything else, inherit parent sampling decision or use 0.5
return inheritOrSampleWith(0.5);
}
});
```
```
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,24 @@ Sentry.init({
tracesSampler: (samplingContext) => {
// Access transaction details from the sampling context
const { name, attributes, inheritOrSampleWith } = samplingContext;

// Skip health checks entirely
if (name.includes('healthcheck')) {
return 0;
}

// Capture all auth-related transactions
if (name.includes('auth')) {
return 1;
}

// Sample only 1% of comment-related transactions
if (name.includes('comment')) {
return 0.01;
}

// For everything else, inherit parent sampling decision or use 0.5
return inheritOrSampleWith(0.5);
}
});
```
```
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,24 @@ Sentry.init({
tracesSampler: (samplingContext) => {
// Access transaction details from the sampling context
const { name, attributes, inheritOrSampleWith } = samplingContext;

// Skip health checks entirely
if (name.includes('healthcheck')) {
return 0;
}

// Capture all auth-related transactions
if (name.includes('auth')) {
return 1;
}

// Sample only 1% of comment-related transactions
if (name.includes('comment')) {
return 0.01;
}

// For everything else, inherit parent sampling decision or use 0.5
return inheritOrSampleWith(0.5);
}
});
```
```
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,24 @@ Sentry.init({
tracesSampler: (samplingContext) => {
// Access transaction details from the sampling context
const { name, attributes, inheritOrSampleWith } = samplingContext;

// Skip health checks entirely
if (name.includes('healthcheck')) {
return 0;
}

// Capture all auth-related transactions
if (name.includes('auth')) {
return 1;
}

// Sample only 1% of comment-related transactions
if (name.includes('comment')) {
return 0.01;
}

// For everything else, inherit parent sampling decision or use 0.5
return inheritOrSampleWith(0.5);
}
});
```
```