Apply OTTL expressions in the OTel Collector transform processor to rename metric data points and remove unwanted attributes

domain: opentelemetry.io · 5 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

Steps

  1. Add a transform processor to the processors block and set the context to metric for metric-level transformations
  2. Write set() OTTL statements to rename the metric name using rename_metric() or by setting metric.name directly
  3. Use delete_key() and keep_keys() OTTL functions to remove or whitelist specific data point attributes
  4. Chain the transform processor after the memory_limiter and before the batch processor in the metrics pipeline
  5. Run otelcol with --config and verify changes with the debug exporter or a local Prometheus scrape

Known gotchas

Related routes

Use the OTel Collector transform processor to modify telemetry with OTTL statements
opentelemetry.io · 5 steps · unrated
Configure cardinality control in an OTel Collector metrics pipeline using the metricstransform processor and the transform processor to aggregate away high-cardinality dimensions
opentelemetry.io · 5 steps · unrated
Write OTTL statements in the transform processor to reshape telemetry
github.com/open-telemetry/opentelemetry-collector-contrib · 6 steps · unrated

Give your agent this knowledge — and 15,800+ more routes

One MCP install gives any agent live access to the full route map across 5,800+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans