Observability

RWX can send telemetry to OpenTelemetry compatible providers. This allows you to observe and analyze your RWX usage and performance alongside your application observability data.

Specific Documentation for Providers

Review these guides to get started observing your CI/CD workloads.

RWX Observability with Honeycomb

RWX Observability with Honeybadger

RWX Observability with Sentry

RWX Observability with Grafana

RWX Observability with Pydantic Logfire

RWX Observability with Datadog

RWX Observability with Dash0

RWX Observability with Custom Providers

OpenTelemetry

Traces are sent with the service.name and deployment.environment of rwx.

Creating Custom Child Spans

When an OpenTelemetry provider is configured, RWX exposes the current task's trace context in the task.otel expression context.

  • ${{ task.otel.trace-id }} - the trace ID for the RWX task span
  • ${{ task.otel.span-id }} - the span ID for the RWX task span

Use these values to make spans created inside the task children of RWX's task span. Because these IDs are different for each task run, pass them through environment variables with cache-key: excluded so they do not prevent task cache hits.

tasks:
  - key: instrumented-tests
    run: npm test
    env:
      OTEL_TRACE_ID:
        value: ${{ task.otel.trace-id }}
        cache-key: excluded
      OTEL_SPAN_ID:
        value: ${{ task.otel.span-id }}
        cache-key: excluded

Configure your application or OpenTelemetry setup to read those values as the parent trace context before it starts spans.

Adding Attributes to the RWX Task Span

RWX exposes a $RWX_OTEL_SPAN directory in each task. Write files to this directory to add custom attributes to RWX's span for that task.

The file name becomes the attribute name. Plain files are collected as string attributes, with a single trailing newline trimmed.

tasks:
  - key: annotate-span
    run: |
      echo "checkout" > "$RWX_OTEL_SPAN/app.phase"
      echo "api" > "$RWX_OTEL_SPAN/app.service"

Use .json files for non-string attributes. RWX strips the .json suffix from the attribute name. JSON values must be a string, number, boolean, or an array of one primitive type with optional null elements.

tasks:
  - key: annotate-span
    run: |
      echo "42" > "$RWX_OTEL_SPAN/app.changed_files.json"
      echo "true" > "$RWX_OTEL_SPAN/app.cache_hit.json"
      echo '["api", null, "worker"]' > "$RWX_OTEL_SPAN/app.components.json"

Avoid using RWX's built-in OpenTelemetry attribute names for custom values. RWX-managed attributes take precedence when the same attribute name is set.