feat(ha-repl-hardening): per-standby convergence tracking from heartbeats (task 3.1)
ha_process_standby_state stores (tag, lsn) per standby, evaluates convergence (tag>=committed && lsn>=committed), sets converged flag, logs INFO only on transition. Wired into repl_ack_decode_and_dispatch. 5 tests: converged, lsn-behind, tag-behind, regression, multi-peer.
This commit is contained in:
parent
7dc657b1bd
commit
aab41fa609
4 changed files with 267 additions and 6 deletions
|
|
@ -71,7 +71,7 @@
|
|||
---
|
||||
|
||||
- [ ] 3. Primary-side: Unified heartbeat-driven replication decision loop
|
||||
- [ ] 3.1 Implement per-standby convergence tracking update
|
||||
- [x] 3.1 Implement per-standby convergence tracking update
|
||||
- On each heartbeat reply from a standby, extract `appliedLsn` and `configTag` from `stateReport`
|
||||
- Store in `standby_reported_tag[idx]` and `standby_reported_lsn[idx]`
|
||||
- Evaluate convergence: `reported_tag >= committed_tag AND reported_lsn >= committed_lsn`
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue