Skip to content

feat(config): make the startup bounds configurable - #357

Closed
EnRaiha wants to merge 1 commit into
fix/calvin-backpressurefrom
feat/startup-tuning-bounds
Closed

EnRaiha wants to merge 1 commit into
fix/calvin-backpressurefrom
feat/startup-tuning-bounds

Conversation

@EnRaiha

@EnRaiha EnRaiha commented Sep 20, 2026 •

Copy link
Copy Markdown
Contributor

Why

Both readiness bounds became hard-coded constants when their [server] fields were removed. Production had carried data_group_recovery_timeout_ms = 600000, and the tighter constants aborted a backlogged start with metadata group applied no entry for 30s / data raft group recovery timeout after 60s instead of waiting the recovery out.

What

Field Default Previous home
[tuning.startup] raft_ready_timeout_ms 300000 [server] raft_ready_timeout_ms (removed)
[tuning.startup] data_group_recovery_timeout_ms 600000 [server] data_group_recovery_timeout_ms (removed)
  • StartupTuning lives beside the other tuning tables in nodedb-types; main.rs threads both bounds into await_cluster_ready, which passes them to wait_for_raft_ready and await_data_group_recovery.
  • A bound written under [server] fails the load with the moved-to path named. from_file checks the parsed table before deserialization, so serde's generic unknown-field list never surfaces for these two keys.
  • docs/getting-started.md documents the section.

How to test

  • defaults_are_five_and_ten_minutes, both_bounds_take_overrides (nodedb-types)
  • from_file_rejects_a_startup_bound_at_its_old_server_path, from_file_rejects_the_legacy_data_group_recovery_bound, from_file_reads_the_startup_bounds_from_tuning
  • cargo test -p nodedb --lib bootstrap:: — 45 pass; from_file_ config tests — 10 pass

Notes

Fixes #354

Tradeoffs

Tradeoff: the two bounds have no NODEDB_* env override yet — the config file is the only source, matching the field's pre-removal shape.

…tup]

Both readiness bounds were hard-coded constants after the config fields
were dropped. raft_ready_timeout_ms (300 s) and data_group_recovery_timeout_ms
(600 s) now live under [tuning.startup], keeping the values that survived the
backlogged recoveries as defaults. A bound still written under [server] is
rejected at load with the moved-to path named.
Copilot AI lite review requested due to automatic review settings September 20, 2026 11:11
@EnRaiha EnRaiha added the run-ci Opt this PR into the full test suite; re-add to force a re-run label Sep 20, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@EnRaiha
EnRaiha added this pull request to stack #358 September 20, 2026 11:14
@EnRaiha EnRaiha added run-ci Opt this PR into the full test suite; re-add to force a re-run and removed run-ci Opt this PR into the full test suite; re-add to force a re-run labels Sep 20, 2026
@farhan-syah

Copy link
Copy Markdown
Member

Closing: targets fix/calvin-backpressure, which conflicts with main. Resubmit against main once #355 is rebased and merged, or fold the two bounds into that PR.

@EnRaiha
EnRaiha removed this pull request from stack #358 September 21, 2026 02:36
@farhan-syah
farhan-syah deleted the feat/startup-tuning-bounds branch September 23, 2026 01:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

run-ci Opt this PR into the full test suite; re-add to force a re-run

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(config): make the startup stall and data-group recovery bounds configurable

3 participants