fix(provider): disable workload healthcheck lease ejection#418
fix(provider): disable workload healthcheck lease ejection#418chalabi2 wants to merge 2 commits into
Conversation
Add coverage for disabling monitor health checks with a zero period. The regression captures the old panic from scheduling zero jitter and asserts that the provider run command does not expose healthcheck flags. Signed-off-by: Joseph Chalabi <chalabi.joseph@gmail.com>
Default post-deploy monitor health checks to off and stop exposing the healthcheck period knobs through provider-service flags. A zero period now returns no schedule instead of panicking or closing stable workloads later. Signed-off-by: Joseph Chalabi <chalabi.joseph@gmail.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (6)
💤 Files with no reviewable changes (3)
WalkthroughThis PR removes default healthcheck period/jitter configuration and their associated CLI flags, replacing healthcheck-based monitor scheduling with retry-based scheduling. ChangesHealthcheck to retry-based monitor scheduling
Estimated code review effort: 3 (Moderate) | ~25 minutes Sequence Diagram(s)sequenceDiagram
participant User
participant RunCmd
participant Config as ProviderConfig
participant Monitor as deploymentMonitor
User->>RunCmd: run with monitor-retry-period flags
RunCmd->>RunCmd: validate FlagMonitorRetryPeriod >= 4s
RunCmd->>Config: set MonitorMaxRetries, MonitorRetryPeriod, MonitorRetryPeriodJitter
Config->>Monitor: initialize with retry-based config
Monitor->>Monitor: scheduleHealthcheck() returns nil (period unset)
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Root cause
The deployment monitor kept scheduling periodic health checks after a workload
had already become healthy. If later status checks failed enough times, the
provider broadcast MsgCloseBid with LeaseClosedReasonUnstable. The healthcheck
period was exposed as operator configuration, so providers could keep this lease
ejection behavior enabled unintentionally.
Verification
Failing-before output from the regression test:
Passing checks: