refactor(bootstrap): BTreeMap for overrides + simplify review #127
Reference in New Issue
Block a user
Delete Branch "refactor/bootstrap-btreemap"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Follow-up cleanup surfaced by the simplify pass on #126 (after merge).
Changes
NumaResolver.overrides:HashMap→BTreeMap. HashMap iteration is randomized per-process (SipHash + random seed), which made the startup override log line order non-deterministic across restarts and required a manual.sort()on the formatted strings. BTreeMap iterates in sorted key order by type invariant — deterministic for free, one less line of code, one less allocation. Lookup cost difference (O(log N) vs O(1)) is under a nanosecond for N=2 and runs once per cold reqwest connection.ips→addrsin theflat_mapso it stops shadowing the outerips: Vec<String>in the same function.sleep 1afterwait—waitalready blocks on child exit. Saves 1s from the suite.No behavior change. Zero-risk.
Validation
cargo test --lib— 354/354cargo fmt --check— cleantests/integration.shSuite 8 — 20/20 (the override-map assertions still pass against the BTreeMap format)Test plan
cargo test --libcargo fmt --checkSUITES=8 ./tests/integration.sh release