prestodb/presto · error · PrestoException
DISTRIBUTED_TRACING_ERROR
DISTRIBUTED_TRACING_ERROR
Error message
SAMPLE_BASED Tracing Mode is currently not supported.
What it means
TracingConfig.setDistributedTracingMode is the @Config binding for tracing.distributed-tracing-mode. The SAMPLE_BASED mode is not implemented, so selecting it is rejected immediately at configuration load with DISTRIBUTED_TRACING_ERROR rather than failing later at runtime.
Source
Thrown at presto-main-base/src/main/java/com/facebook/presto/tracing/TracingConfig.java:74
}
@Config("tracing.enable-distributed-tracing")
public TracingConfig setEnableDistributedTracing(boolean enableDistributedTracing)
{
this.enableDistributedTracing = enableDistributedTracing;
return this;
}
public DistributedTracingMode getDistributedTracingMode()
{
return tracingMode;
}
@Config("tracing.distributed-tracing-mode")
public TracingConfig setDistributedTracingMode(String tracingMode)
{
if (tracingMode.equalsIgnoreCase(DistributedTracingMode.SAMPLE_BASED.name())) {
throw new PrestoException(
DISTRIBUTED_TRACING_ERROR,
"SAMPLE_BASED Tracing Mode is currently not supported.");
}
this.tracingMode = DistributedTracingMode.valueOf(tracingMode.toUpperCase());
return this;
}
}
View on GitHub (pinned to 55bb57d202)
Solutions
- Change tracing.distributed-tracing-mode to ALWAYS_TRACE (the supported mode)
- Remove the tracing.distributed-tracing-mode property to use the default mode
- Upgrade Presto to a version that implements SAMPLE_BASED if sample-based tracing is required
- Leave distributed tracing disabled if sampling semantics are essential and unsupported
Example fix
// before tracing.distributed-tracing-mode=SAMPLE_BASED // after tracing.distributed-tracing-mode=ALWAYS_TRACE
Defensive patterns
Strategy: validation
Validate before calling
String mode = props.getProperty("tracing.distributed-tracing-mode");
if (mode != null && mode.equalsIgnoreCase("SAMPLE_BASED")) {
throw new IllegalArgumentException("tracing.distributed-tracing-mode=SAMPLE_BASED is unsupported; use ALWAYS_TRACE");
} Type guard
boolean isSupportedTracingMode(String mode) {
return mode != null && !mode.equalsIgnoreCase("SAMPLE_BASED");
} Try / catch
try {
config.setDistributedTracingMode(tracingMode);
} catch (PrestoException e) {
if (e.getMessage().contains("SAMPLE_BASED")) {
LOG.warn("SAMPLE_BASED unsupported; falling back to ALWAYS_TRACE");
config.setDistributedTracingMode("ALWAYS_TRACE");
} else {
throw e;
}
} Prevention
- Validate tracing.properties against supported values for your Presto version before deploy
- Use ALWAYS_TRACE (or omit the property) until SAMPLE_BASED ships in your build
- Smoke-test server startup with new tracing config in a staging cluster
- Derive mode values from the DistributedTracingMode enum minus unsupported entries
When it happens
Trigger: Setting tracing.distributed-tracing-mode=SAMPLE_BASED (any casing) in tracing.properties or via equivalent config during server startup.
Common situations: Following documentation or examples written for a newer Presto version that supports SAMPLE_BASED; guessing a mode name from the DistributedTracingMode enum; copy-pasting config from another cluster with a different Presto build.
Related errors
- Plugin-configured tracer provider ('%s') does not match syst
- Only a single plugin should set the tracer provider ('%s').
- %s codec is not supported
- ACCUMULO_TABLE_EXISTS
- UNEXPECTED_ACCUMULO_ERROR
AI-assisted analysis of prestodb/presto@55bb57d202 (2026-09-04).
Data as JSON: /api/errors/988fbfc40bbf3d3e.
Report an issue: GitHub.