Skip to content

[server] Reconcile divergent replica logs using leader epochs - #4273

Open
platinumhamburg wants to merge 4 commits into
apache:mainfrom
platinumhamburg:investigate-leader-migration-wal
Open

[server] Reconcile divergent replica logs using leader epochs#4273
platinumhamburg wants to merge 4 commits into
apache:mainfrom
platinumhamburg:investigate-leader-migration-wal

Conversation

@platinumhamburg

Copy link
Copy Markdown
Contributor

Track durable leader epoch boundaries and exchange optional epoch metadata during replication to reconcile divergent tails after leader migration.

Preserve legacy replication compatibility and support a dynamically configurable, default-enabled epoch mode. Cover divergence, mixed-mode replication, dynamic configuration changes, and remote recovery.

Purpose

Linked issue: close #4269

Brief change log

Tests

API and Format

Documentation

@platinumhamburg
platinumhamburg force-pushed the investigate-leader-migration-wal branch 2 times, most recently from 8724a3a to 8922ff3 Compare September 11, 2026 12:35
Track durable leader epoch boundaries and exchange optional epoch metadata during replication to reconcile divergent tails after leader migration.

Preserve legacy replication compatibility and support a dynamically configurable, default-enabled epoch mode. Cover divergence, mixed-mode replication, dynamic configuration changes, and remote recovery.
Preserve durable epoch boundaries on restart and follower progress on leader reelection. Correct the test endpoint leader identity and verify follower high watermark convergence.

Regenerate Rust protobuf bindings and keep scanner requests free of replication-only epoch metadata.
Propagate append IOExceptions to the replica fatal error handler after invalidating epoch history. Retry remote segment cleanup when the high watermark reaches the committed remote boundary.

Exercise ISR recovery through a real follower restart without creating inconsistent leader epochs.
@platinumhamburg
platinumhamburg force-pushed the investigate-leader-migration-wal branch from a7d6751 to e471515 Compare September 12, 2026 14:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Server] Clean leader reassignment can leave divergent WAL in an ISR replica

1 participant