GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||
GeezerVison is showing github.com — [connectors] Give transport output endpoints a health and metrics channel by bestouff · Pull Request #7639 · feldera/feldera Conversation
|
| Method | Controller side |
|---|---|
error |
output_transport_error, as before |
update_connector_health |
update_output_connector_health |
set_custom_metrics |
ControllerStatus::set_output_custom_metrics |
No connector changes behavior. Next PRs: #7653, #7682, #7683.
Engine test output_endpoint_callbacks_reach_status_and_metrics pushes a gauge, health and an error through the channel and checks the endpoint status and the Prometheus text. It then removes the endpoint and stops the controller, and checks that late reports through the same callbacks do nothing. Clippy -D warnings, cargo fmt and cargo check --all-targets pass. The broker tests were not run; their changes only rename an argument.
feldera-adapterlib crate APIOutputEndpoint::connect now takes Arc<dyn OutputEndpointCallbacks>; the hidden AsyncErrorCallback type is removed. External implementations adapt the signature and call callbacks.error(...).
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
LGTM. This is a refactor that changes no connector's behaviour. The new channel to the controller is wired correctly: What I ran
I couldn't run the Kafka and NATS endpoint tests, because they need brokers. Their changes only rename things. Pitfall (medium): Missing test (low, follow-up is fine): No test calls the callbacks after the endpoint has been removed. That path should be a silent no-op, because |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
The non-fault-tolerant Kafka sink dropped undelivered messages after librdkafka's five-minute default timeout while the pipeline kept running. Default to unbounded delivery retries so a sustained outage fills the producer queue and applies backpressure. Preserve either explicit timeout alias so deployments can retain a finite deadline. Report health from pending delivery age and delivery results. An enqueue can succeed because a failed delivery freed space, so it cannot establish recovery. A periodic task on the shared runtime detects quiet stalled sinks even with statistics disabled. Track delivery identities so progress on one partition cannot hide an older pending record on another. Expose queue, request, delivery, and wait metrics through the output callback API. Keep broker counters monotonic across resets and include active and interrupted queue waits. Log temporary disconnections without reporting lost output. Document the changed default and its limits. Validate timeout aliases, outage recovery and payloads, quiet sinks, expiry followed by enqueue, out-of-order delivery, fatal health, counter resets, and cancellation. Check controller callback forwarding and backpressure with the static engine. The alias and enqueue-health tests fail when their respective fixes are removed. Second step for #7578, stacked on #7639.
|
LGTM. This refactor keeps behaviour the same: the error path still goes through What I ran
Gates: tests ✅, flaky ✅, no Gaps (medium):
|
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Looks as I'd expect. I read the changes except that I just skimmed the test changes.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
6a5b699 to
886f05b
Compare
…nnel A transport output endpoint got only an error closure from `OutputEndpoint::connect`. It had no way to report its health or to export its own metrics, which only integrated sinks could do because they hold the controller. Replace the closure with the trait object `OutputEndpointCallbacks`, the output counterpart of the reporting methods of `InputConsumer`: | Method | Controller side | |---------------------------|---------------------------------------| | `error` | `output_transport_error`, as before | | `update_connector_health` | `update_output_connector_health` | | `set_custom_metrics` | `ControllerStatus::set_output_custom_metrics` | The two Kafka sinks keep the trait object where they kept the closure. The other endpoints ignore it as they ignored the closure. Tests that drive an endpoint without a controller use `MockOutputCallbacks`. The new controller test connects an endpoint that reports a gauge, its health and an error through the channel, and checks the endpoint status and the Prometheus text. With the health and metrics forwarding stubbed out, it fails on the health assertion. First step for #7578: the Kafka sinks need this channel to show queue depth and to report themselves unhealthy while they retry. Signed-off-by: Xavier Bestel <[email protected]>
The non-fault-tolerant Kafka sink dropped undelivered messages after librdkafka's five-minute default timeout while the pipeline kept running. Default to unbounded delivery retries so a sustained outage fills the producer queue and applies backpressure. Preserve either explicit timeout alias so deployments can retain a finite deadline. Report health from pending delivery age and delivery results. An enqueue can succeed because a failed delivery freed space, so it cannot establish recovery. A periodic task on the shared runtime detects quiet stalled sinks even with statistics disabled. Track delivery identities so progress on one partition cannot hide an older pending record on another. Expose queue, request, delivery, and wait metrics through the output callback API. Keep broker counters monotonic across resets and include active and interrupted queue waits. Log temporary disconnections without reporting lost output. Document the changed default and its limits. Validate timeout aliases, outage recovery and payloads, quiet sinks, expiry followed by enqueue, out-of-order delivery, fatal health, counter resets, and cancellation. Check controller callback forwarding and backpressure with the static engine. The alias and enqueue-health tests fail when their respective fixes are removed. Second step for #7578, stacked on #7639. Signed-off-by: Xavier Bestel <[email protected]>
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.