Skip to content

feat(observability): wire Phase B causal audit boundaries - #6574

Draft
RuroninMugen wants to merge 5 commits into
block:mainfrom
RuroninMugen:feature/hive-phase-b-observability-prod
Draft

feat(observability): wire Phase B causal audit boundaries#6574
RuroninMugen wants to merge 5 commits into
block:mainfrom
RuroninMugen:feature/hive-phase-b-observability-prod

Conversation

@RuroninMugen

@RuroninMugen RuroninMugen commented Aug 22, 2026

Copy link
Copy Markdown

Summary

Adds the production-only Phase B causal observability layer for buzz-acp.

This PR introduces a local, metadata-only, fail-open JSONL audit sink and wires seven production observation boundaries:

  • TransportPublished
  • TransportAccepted
  • EventReceived
  • FilterDecision
  • QueueDecision
  • WakeDecision
  • AcpSessionStarted

Safety / behavior

  • auditing is disabled by default
  • no blocking filesystem I/O occurs on hot paths
  • bounded channel + try_send prevents backpressure from affecting business logic
  • filesystem/writer failures fail open
  • audit payloads exclude raw prompts, message bodies, relay text, API keys, private keys, and auth tokens by construction
  • no dependency changes

Validation

Validated on current upstream main before push:

  • rustup run 1.95.0 cargo check -p buzz-acp — PASS
  • rustup run 1.95.0 cargo clippy -p buzz-acp --all-targets — exit 0, warnings only
  • rustup run 1.95.0 cargo test -p buzz-acp — 810 passed, 0 failed

All five commits carry DCO Signed-off-by trailers.

Scope / known limitations

This PR is intentionally production-only. The separate Phase 5B regression-test commit is not included here.

Known limitations:

  • ResponsePublished is declared in the schema but not yet wired to a production emit site.
  • RecipientEvidenceObserved is declared in the schema but not yet wired to a production emit site.
  • TransportPublished / TransportAccepted describe internal buzz-acp WebSocket transport observations; they are not proof of real outbound agent handoff/chat publication through buzz-cli.
  • correlation_id_for is currently unused.
  • fail-closed FilterDecision emitted-payload coverage and B7→B8 cross-record correlation remain follow-up test work.

The original combined PR #6559 remains untouched; this PR replaces only its production portion with a clean, DCO-signed branch based on current upstream main.

Signed-off-by: rudy valace <rudyvalace@gmail.com>
Signed-off-by: rudy valace <rudyvalace@gmail.com>
Signed-off-by: rudy valace <rudyvalace@gmail.com>
Signed-off-by: rudy valace <rudyvalace@gmail.com>
Signed-off-by: rudy valace <rudyvalace@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant