← Back to Pull requests

fix: count an in-window reboot recovery seen after the deadline #3652

Open
unknown opened this pull request with 234 lines diff across 2 files
View on GitHub
unknown unknown commented on Nov 19, 2026 12:28 UTC
Author

Fixes #3533

Description
The reboot controller checked the phase deadline before it looked at the node. A node that rejoined inside the observation window was still marked recovery_timeout and replaced when the next reconcile ran after the window, including after a controller restart.
Recovery is now evaluated first. A new boot ID and Ready=True whose transition is at or before the end of the window becomes RebootSucceeded, even if that reconcile runs later. A Ready transition after the window still ends as recovery_timeout. A Ready transition from before issuance counts as issuance time, so a fast reboot that never leaves Ready=True is still inside the window.
The same ordering applies while the reboot is still being issued. If the provider returns an error but the node reboots anyway, a check after the 5-minute issuance timeout moves the reboot into observation instead of replacing the node with provider_error.

How was this change tested?
go test ./pkg/controllers/nodeclaim/reboot/ -count=1
Covers:

  • Ready at 19m55s, first seen at 20m10s, succeeds

  • Ready at 20m05s, first seen at 20m10s, recovery_timeout

  • Ready transition from before issuance, first seen after the window, succeeds

  • Boot changed but not Ready after the window, recovery_timeout

  • Boot already changed when the issuance check lands after the timeout, moves to observation and then succeeds
  • AI Disclosure <!-- Per https://www.kubernetes.dev/docs/guide/pull-requests/#ai-guidance. Only check the boxes that apply. -->

  • I used AI assistance to help produce this contribution.

  • I have verified the AI generated code prior to submission.

  • I will engage with review comments directly and will not use AI to write my replies.
  • By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

    Diff: 234 lines (+175 / -59) across 2 files Reviewer: HarshithaMS005 Review duration: 16858m
    All Vouch review confidence checks passed
    Residual risk 0.20 = Change Risk (0.37) × (1 − Review Confidence (0.47)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.37 · 234 lines diff across 2 files
    0.37
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.02 · 1 substantive comment(s)
    0.02
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    46%
    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
    Shallow Review Depth shallow_review_depth
    0.344
    Diff Size diff_size
    0.327
    Real PR Conversation Timeline
    1 comments
    "Review active on #3652"
    general weight: 0.35
    Assignees
    Unassigned
    Labels
    risk: low confidence: 46.7% 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: 37.1% (MEDIUM) · Higher = larger blast radius
    37.1%
    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: 46.7% · Lower = rushed or shallow review
    46.7%
    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: 19.8% · Safe to merge
    19.8%