patch(v2.2): restore the external FMDS connection gauge - #5676
Conversation
Backport `48a8e0ce2` from NVIDIA#5663 to `release/v2.2`. The reconnect change from NVIDIA#4989 is already in v2.2, but the branch was cut before main restored `carbide_dpu_agent_fmds_external_connected`. An agent configured for external FMDS therefore retries connections without exposing the established connection gauge. Register the gauge for external FMDS and update it after every completed connection attempt. Record the connection result before sending metadata so a successful connection followed by a rejected update still reports `1`; a later connection failure reports `0`. This supports NVIDIA#5670 Signed-off-by: Chet Nichols III <chetn@nvidia.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d1ed4dd8df
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| .u64_observable_gauge("carbide_dpu_agent_fmds_external_connected") | ||
| .with_description( | ||
| "Result of the DPU agent's latest connection attempt to its configured external FMDS (1 for success, 0 before success or after failure)", |
There was a problem hiding this comment.
Add the restored gauge to the generated metric catalogue
The repository-wide search finds this metric only in the implementation and the agent unit-test fixture; docs/observability/core_metrics.md still has no carbide_dpu_agent_fmds_external_connected entry. Consequently, operators using the generated metrics reference cannot discover the restored gauge, and the HELP/emitted/catalogue surfaces disagree. Exercise it through test_integration and regenerate the catalogue rather than updating only the unit fixture.
AGENTS.md reference: AGENTS.md:L391-L400
Useful? React with 👍 / 👎.
Backports
48a8e0ce2from #5663 torelease/v2.2.The reconnect change from #4989 is already in v2.2, but the branch was cut before main restored
carbide_dpu_agent_fmds_external_connected. An agent configured for external FMDS therefore retries connections without exposing the established connection gauge.This registers the gauge for external FMDS and updates it after every completed connection attempt. It records the connection result before sending metadata, so a successful connection followed by a rejected update still reports
1; a later connection failure reports0.Related issues
Type of Change
Breaking Changes
Testing
Unit tests added/updated
Integration tests added/updated
Manual testing performed
No testing required (docs, internal refactor, etc.)
cargo test -p carbide-agent fmds_clientandcargo test -p carbide-agent tests::metrics::test_metricspass all four focused tests for connection state and the exported gauge.cargo make format-nightlyandcargo make clippypass. The full custom lint traversal stops on two existingtxn_held_across_awaitfindings in unchangedcrates/api-core/tests/integration/dns_resolution.rs.Review Findings
Model Findings Overview
The local model reviews were not repeated for this backport. The stable patch ID is
0129a06def0d44cff404b5c9a251600073631b7ffor both this branch and the reviewed patch from #5663, and no code was changed after the cherry-pick.Model Findings Details
Per Chet's direction, the Codex, CodeRabbit CLI, Claude CLI, and common-nits passes were not rerun. No additional review findings or edits were produced, and no hosted CodeRabbit review was requested.