Repository navigation
Closed
Labels
P2: mediumMinor bug, missing validation, metric inaccuracyMinor bug, missing validation, metric inaccuracyarchitectureSystemic design improvements that eliminate classes of bugsSystemic design improvements that eliminate classes of bugscomponent:diagnosticsDiagnostics endpoints, dashboard, health, probes, and trace explorerDiagnostics endpoints, dashboard, health, probes, and trace explorercomponent:output/commonCross-cutting output behavior spanning multiple sinksCross-cutting output behavior spanning multiple sinkscomponent:pipelinePipeline orchestration, batching, runtime flow, and worker coordinationPipeline orchestration, batching, runtime flow, and worker coordinationenhancementNew feature or requestNew feature or requestproductionRequired for production readinessRequired for production readinesswork-unitScheduling ticket for one agent runScheduling ticket for one agent run
Description
work-unit: control plane — output lifecycle status wiring
Purpose
Wire output-side lifecycle truth into the shared control-plane model after the shared status types and probe semantics are established.
This batch is intentionally downstream of #1414 and #1413: it makes sink startup, degradation, retry pressure, fatal failure, and shutdown visible through the common status model without attempting the full exporter redesign in one pass.
Repo footprint
crates/logfwd/src/worker_pool.rscrates/logfwd-output/src/sink.rs- representative concrete sinks in
crates/logfwd-output/src/ crates/logfwd/tests/andcrates/logfwd-output/tests/
In scope
| # | Type | Why included |
|---|---|---|
| #1306 | architecture | sink-side lifecycle is part of the shared control-plane substrate |
| #1312 | architecture | output semantics need explicit runtime status, especially around retries and failures |
| #1313 | architecture | file appender should participate in the same shared lifecycle/status model |
Related metas / phases
- should follow
#1414shared status model and#1413probe truth - adjacent behavior work:
#1443retry/status helpers and#1272fanout delivery contract bugs - temporary cleanup-wave coordination only:
#1450
Non-goals
- no fanout atomicity redesign (that stays in
#1272/#1312) - no retry/backoff architecture rewrite beyond surfacing status honestly
- no restoration of missing sink types
- no broad output config work
Done when
- worker-pool and sink lifecycle states feed the shared status model
- startup, degraded/retrying, failed, and stopping sink states are visible in diagnostics
- readiness reflects the chosen sink-health policy rather than defaulting to healthy forever
- representative sink / worker-pool tests cover startup, retry pressure, fatal failure, and clean shutdown
Metadata
Metadata
Assignees
Labels
P2: mediumMinor bug, missing validation, metric inaccuracyMinor bug, missing validation, metric inaccuracyarchitectureSystemic design improvements that eliminate classes of bugsSystemic design improvements that eliminate classes of bugscomponent:diagnosticsDiagnostics endpoints, dashboard, health, probes, and trace explorerDiagnostics endpoints, dashboard, health, probes, and trace explorercomponent:output/commonCross-cutting output behavior spanning multiple sinksCross-cutting output behavior spanning multiple sinkscomponent:pipelinePipeline orchestration, batching, runtime flow, and worker coordinationPipeline orchestration, batching, runtime flow, and worker coordinationenhancementNew feature or requestNew feature or requestproductionRequired for production readinessRequired for production readinesswork-unitScheduling ticket for one agent runScheduling ticket for one agent run
Activity
github-actions commentedon Apr 6, 2026
tl;dr: Outcome A — Ready for implementation. The core blocker is already concrete: output lifecycle/readiness cannot be wired correctly because worker-pool acks collapse sink outcomes to
success: bool, and readiness is currently independent of sink health.Recommendation
Implement this issue as a focused protocol+diagnostics wiring change in
worker_pool+pipeline+diagnostics+ output tests: carry sink/lifecycle state throughAckItem, update per-sink diagnostics, and gate readiness by explicit sink-health policy.Findings
Ack protocol is too lossy for lifecycle truth
crates/logfwd/src/worker_pool.rs:82-87Pipeline currently records output failure against pipeline name, not sink name
crates/logfwd/src/pipeline.rs:979crates/logfwd/src/pipeline.rs:331-337, 342-349(metrics.add_output(&output_name, ...))output_errormatches by output name only:crates/logfwd-io/src/diagnostics.rs:197-203.Readiness does not use sink health at all
crates/logfwd-io/src/diagnostics.rs:553-555545-552).Known in-code limitation confirms this gap
crates/logfwd/src/pipeline.rs:2382-2383// Per-sink error tracking ... not currently supported by the pool's AckItem protocolVerification
Ran targeted existing readiness tests:
cargo test -p logfwd-io ready_endpoint -- --nocaptureOutput:
test_ready_endpoint_no_pipelines_returns_503 ... oktest_ready_endpoint_with_pipeline_returns_200 ... okThis confirms current
/readybehavior is purely pipeline-registration based.Detailed Action Plan (mechanical)
Extend worker ack semantics to carry sink lifecycle/status
crates/logfwd/src/worker_pool.rs(AckItemat82-105,process_itemat565+,worker_taskat459+)AckItem:sink_name: String(or interned/static variant)outcome: OutputOutcome(new enum)attempts,last_retry_after_ms)(bool, send_latency_ns)return fromprocess_itemwith structured outcome (OutputOutcome) + latency.SendResult::Ok→DeliveredRetryAfter/...with eventual success/failure →RetriedThenDelivered/RetryExhaustedRejected→PermanentFailureFatalFailure/StoppingAbortedFix pipeline wiring to per-sink metrics and lifecycle
crates/logfwd/src/pipeline.rs(apply_pool_ackat965-982)output_error(self.name.as_str())with sink-name-aware update fromAckItem.ack_all_tickets) while enriching diagnostics state.Add sink lifecycle/readiness model to diagnostics
crates/logfwd-io/src/diagnostics.rsPipelineMetricswith sink-status storage (per output):starting|ready|degraded|failed|stopping+ timestamps./api/pipelinespayload to expose per-output lifecycle + retry pressure counters./ready(serve_readyat553-568) to evaluate configured sink-health policy instead of only!pipelines.is_empty().Introduce configurable readiness policy (minimal explicit policy)
crates/logfwd-config/src/...(server/output readiness config model)crates/logfwd/src/main.rsand/or pipeline bootstrap wiringAnySinkReady(lenient)AllSinksReady(strict)AllowDegradedFor: DurationTests to write (representative and mechanical)
crates/logfwd/src/worker_pool.rstests moduleAckItem.outcome.crates/logfwd/src/pipeline.rstests (neartest_async_fanout_output_errors_only_increment_failing_output)crates/logfwd-io/src/diagnostics.rstests (near ready endpoint tests at1634+)Verification commands
cargo test -p logfwd-io diagnostics::tests::test_ready_endpoint_no_pipelines_returns_503 diagnostics::tests::test_ready_endpoint_with_pipeline_returns_200cargo test -p logfwd --lib worker_poolcargo test -p logfwd --lib pipelinejust ciRelated Items
crates/logfwd/src/worker_pool.rs:82success: bool)crates/logfwd/src/pipeline.rs:979crates/logfwd-io/src/diagnostics.rs:553/readycurrently ignores sink healthNote
🔒 Integrity filtering filtered 7 items
Integrity filtering activated and filtered the following items during workflow execution.
This happens when a tool call accesses a resource that does not meet the required integrity or secrecy level of the workflow.
issue_read: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)issue_read: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)issue_read: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)issue_read: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)issue_read: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)issue_read: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)search_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)What is this? | From workflow: Issue Triage
Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.
strawgate commentedon Apr 6, 2026
The first pure-seam extraction batch under this work-unit is now #1439 (
logfwd-outputsink and fanout health policy).That gives us a merge-safe local slice before the broader sink lifecycle wiring work lands.
[-]work-unit: logfwd-output + worker_pool — sink lifecycle, degradation, and failure wiring[/-][+]work-unit: control plane — output lifecycle status wiring[/+]strawgate commentedon Apr 7, 2026
Resolved by PRs #1454, #1480, #1505. Verified: OutputHealthEvent reducer, per-worker health tracking.