← Back to Pull requests

fix: bound resource operation monitoring deadlines #7588

Closed
unknown closed this pull request without merging on Oct 27, 2026 16:18 UTC
View on GitHub
unknown unknown commented on Oct 16, 2026 15:27 UTC
Author

Why

Resource operations must terminate when provisioning cannot complete, including ExternalAuth creates repeatedly rejected by Cluster Service before a CS ID is assigned. Missing deadlines and observation-error early returns previously allowed monitoring to continue indefinitely. This originated from a directly supplied incident; no tracking ticket was supplied.

Changes

Two ordered commits:
1. Add the AFEC-gated aro-hcp.experimental.nodepool.max-deletion-duration tag and persist its validated budget during PUT/PATCH admission.
2. Initialize and enforce resource deadlines, consume the node-pool override on DELETE, and preserve partial status diagnostics.

| Resource | Create | Update | Delete |
|---|---:|---:|---:|
| Cluster | 60m | 90m | 50m |
| Node pool | 60m | 90m | 50m |
| ExternalAuth | 30m | 30m | 30m |

Defaults are twice the shared E2E operation budgets, using the version-upgrade budget for cluster/node-pool updates. Existing experimental overrides are preserved. ExternalAuth remains fixed-budget because its ProxyResource API has no tags; no parent-tag inheritance is introduced.

Create/update controllers collect their normal status checks once and retain successfully observed diagnostics alongside observation errors. Fully observed terminal outcomes, including success observed after expiry, win. Before expiry, observation errors remain retryable; after expiry, incomplete observation cannot prevent timeout. Raw observation errors are not exposed in the ARM error. Missing CS IDs remain pending and eligible for timeout. Delete monitors check expiry before dispatch prerequisites while preserving missing-document success. Cluster-delete timeout errors now use DeadlineExceeded consistently with other delete monitors.

Deadlines are persisted on acceptance. Existing nil deadlines are not backfilled. Accepted delete retries refresh monitoring deadlines without resetting deletion progress; cleanup continues after monitoring fails. PUT/PATCH admission rejects resources with deletion intent even if a timeout changed provisioning state to Failed; DELETE retries remain allowed. Admission accumulates errors consistently.

Credential lifecycle changes remain separate in #7589. Generated lifecycle documentation is maintained separately by the documentation bot under current repository policy.

Verification

  • go test ./backend/... passed.

  • go test ./frontend/... ./internal/admission ./internal/api/coreapi ./internal/api/metadataapi passed.

  • Fresh focused race tests passed for all three resource-operation packages, operationutils, admission, and frontend.

  • Targeted golangci-lint passed for the changed backend, frontend, and internal packages with zero issues.

  • Regenerated deepcopy; diff checks passed.

  • Tests cover partial observation errors, success after expiry, missing CS IDs, deadline boundaries, operation ownership, notifications, deletion retries, override consumption, and rejected updates during deletion.
  • Real Cosmos and live E2E validation were not run. Remote CI and human review remain required.

    Diff: 384 lines (+288 / -96) across 4 files Reviewer: miguelsorianod Review duration: 15891m
    All Vouch review confidence checks passed
    Residual risk 0.17 = Change Risk (0.43) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.43 · 384 lines diff across 4 files
    0.43
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.356
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #7588"
    general weight: 0.35
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 43% (MEDIUM) · Higher = larger blast radius
    43%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 17.0% · Safe to merge
    17.0%
    Repository