Skip to content

er-api span export died silently for a whole pod lifetime — nothing alarms on absent spans #941

Closed

Description

@athvin

Found 2026-11-09 during the #660 live re-probe · observability · estimate 0.5 eng-weeks

The web-api-green-687d84c7bc-rx85r pod (ci ns, image er-api@1dafadd14531, started 2026-11-08 23:43:49Z) exported zero spans for its entire 40-minute lifetime while logging spans to stdout normally and exporting metrics to the same collector endpoint continuously. It self-healed only when the pod was deleted for an unrelated reason; the replacement pod (same image, same spec) exported immediately. This is the exact failure er-obs/src/otlp.rs warns about: a telemetry pipeline that looks installed and exports nothing — except the boot log line OTLP span export installed was present and correct.

Evidence

  • OpenObserve: last er-api span before the outage 2026-11-08 22:59Z (previous pod's boot); next 2026-11-09 00:25Z (after the restart). er-dispatcher — same image, same collector — exported ~193k spans across the same window.
  • The pod's own stdout shows the request spans being recorded with the right attributes (http.request.method=POST, http.route=/v1/orgs) at 23:56:56Z and 00:04:58Z — so spans were created and ended; they never left the process (or were rejected silently).
  • er-api metric series (er_db_query_duration_count) has data points throughout the outage, including 30s before the pod was deleted — the reqwest/HTTP machinery, DNS and network path from this pod to otel-collector:4318 were all working.

Eliminated during the hunt (each tested live)

  • Collector / tail-sampling: a synthetic er-api span POSTed from the same pod's er-web container to the same endpoint was accepted (200) and landed in OpenObserve, kept by the mutations policy.
  • Code regression: the only Rust delta between the last-exporting image and this one is The engine cannot open an s3:// lake — build the object-store credential path #792 (7ca3dbb4) — additive env-filter code in er-server, no er-obs or dependency changes (Cargo.lock untouched).
  • NetworkPolicy: only default-deny-ingress exists in the ns; egress is unrestricted.
  • Pod env: OTEL_EXPORTER_OTLP_ENDPOINT identical to the working dispatcher; boot log confirms the traces endpoint built.

What this needs

  1. Detection first — the gap that made this expensive: nothing notices when a role's spans go absent. An alert on count(er-api spans) == 0 over N min while the process is up and serving (the metric series for the same role is the liveness reference — it kept flowing through the whole outage) would have paged on this within minutes instead of being found by accident during another ticket's probe.
  2. Root cause — reproduce per-boot span-export death. Suspects: the batch span processor's thread dying at boot without a log line, the export_runtime() OnceLock failing once, or the exporter wedging on a transient collector error at first flush (the outage boot coincided with a same-minute dispatcher roll). Consider making span-export failure loud (a boot-time self-test span plus a warn when the exported-span counter stays zero while ended spans accumulate) so the next occurrence announces itself in the pod log instead of in a missing-data query.

Full hunt log in the #660 closing comment.

Activity

  1. self-assigned this
    on Nov 9, 2026
  2. athvin commented on Nov 9, 2026

    @athvin
    OwnerAuthor

    Claiming — picking this up now. Detection half first: self-reported span counters in er-obs (they ride the metric pipeline that kept flowing through the outage), then a CloudWatch alarm on absent er-api spans while the process is live.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions