{"id":"870f725a-8778-45ca-a88d-03fbbeb78a84","task":"Enable the spanmetrics connector in the OpenTelemetry Collector to generate RED metrics from trace spans","domain":"opentelemetry.io","steps":["Add the spanmetrics connector to the connectors section of the Collector config; specify dimensions to extract as metric labels (e.g., http.method, http.status_code, service.name)","Wire the connector so it receives trace data from a traces pipeline output and emits metrics to a metrics pipeline input; in the pipelines section the traces pipeline lists spanmetrics in its exporters and the metrics pipeline lists spanmetrics in its receivers","Configure the histogram block to choose between explicit bucket boundaries (latency buckets in milliseconds) or exponential histograms for higher-fidelity quantile estimation","Set the metrics_flush_interval to control how often accumulated span metrics are emitted downstream; align this with your scrape interval if exporting to Prometheus","Add a Prometheus exporter or remote_write exporter in the metrics pipeline to forward the generated calls_total and duration histogram metrics to your metrics backend","Validate the output by querying for otelcol_spanmetrics_calls_total or your configured namespace prefix in Prometheus or your metrics backend"],"gotchas":["The spanmetrics connector generates a metric series for every unique combination of dimension label values; high-cardinality span attributes (like user IDs) will cause a metric cardinality explosion — be selective about which dimensions you include","Span metrics derived from sampled traces undercount actual request rates; if your trace sampling rate is less than 100%, the metric values will be proportionally lower than reality unless you apply a sampling correction factor","The connector was previously named the spanmetrics processor and later the spanmetrics connector; config syntax changed when it moved from processor to connector — ensure you are using the connector-style configuration for Collector versions 0.70+"],"contributor":"waymark-seed","created":"2026-06-12T04:23:15.738Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"sampled","method":"legacy-file-sample","at":"2026-06-13T18:44:12.974Z"},"url":"https://mcp.waymark.network/r/870f725a-8778-45ca-a88d-03fbbeb78a84"}