-
Notifications
You must be signed in to change notification settings - Fork 180
fix(machine-a-tron): add discovery_retry_interval knob #5072
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -182,6 +182,8 @@ machineDefaults: | |
| dpuRebootDelay: 1 | ||
| hostRebootDelay: 1 | ||
| scoutRunInterval: "60s" | ||
| ## Delay after a failed DiscoverMachine call; the default matches the production DPU agent. | ||
| discoveryRetryInterval: "60s" | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should we make sure we don't allow 0 to be passed? the behavior would remain the same if someone was to pass 0
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We don't have similar checks for other fields in this helm. If we want to introduce these checks we need to add it to all fields instead of adding one-off check here. |
||
| runIntervalWorking: "1s" | ||
| runIntervalIdle: "10s" | ||
| networkStatusRunInterval: "20s" | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win
Reject zero discovery retry intervals.
Duration::ZEROremains valid through direct Rust construction, andMachineATronConfig::validatedoes not check this field.crates/machine-a-tron/src/machine_state_machine.rsLine 600 returns the interval directly while the failed discovery action remains queued. A zero value can therefore create an immediate retry loop and repeated API requests.Reject zero in configuration validation for machine and rack configurations. Add a table-driven validation test.
As per path instructions, this is a runtime availability risk in a
crates/**/*.rschange, not a style concern.Also applies to: 170-175, 251-256
🤖 Prompt for AI Agents
Source: Path instructions