block / block/buzz

Add early process lifecycle observability

Open
#7,238 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Rust
Stars
32.7k
Forks
4.3k
Avg merge
1d 13h
Merged PRs (30d)
253

Description

🤖

**Motivation**

Buzz can currently crash before readiness without one typed, ordered application record identifying whether crypto installation, tracing initialization, configuration loading, key loading, or Prometheus binding failed. Metrics setup also panics on known installation failures and detaches the exporter task.

**Proposed solution**

- Add a process lifecycle/boot tracker at relay process entry with a closed phase, result, and reason vocabulary.
- Give each startup phase an owned terminal guard with an explicit abandoned fallback for in-process paths that forget to terminalize.
- Emit a bounded single-line lifecycle event before tracing exists, then use the same schema through structured tracing after initialization.
- Make metrics installation return a typed result and retain supervision of the exporter lifecycle.
- Add only survivor-aware fleet metrics for observed process-to-metrics-ready outcome and duration.
- Add production-seam child-process tests for invalid config, occupied metrics port, early panic/error behavior, exact terminal accounting, and secret-safe output.
- Deploy the exact image to staging, read back the log/metric contract, and add an Early process startup row to the Buzz Startup & Rollout Safety dashboard.

**Alternatives considered**

Metrics-only telemetry cannot report failures that happen before the metrics listener exists. Unstructured logs do not provide bounded phases, exact terminal accounting, or safe fleet aggregation. Kubernetes remains authoritative for process existence and hard-kill disappearance.

**Additional context**

No duplicate issue was found in the open `block/buzz` issue search for startup lifecycle/process telemetry. Design notes: `/Users/rarora/.buzz/PLANS/BUZZ_POD_HANDOFF_IMPLEMENTATION_PACKAGES.md` Package 1 and `/Users/rarora/.buzz/RESEARCH/BUZZ_POD_HANDOFF_NEXT_PACKAGE_2026_09_02.md`.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.