How Database Replication Works (mostly in Postgres)
Comments
Ranked by a public rubric, not by votes: what a comment adds counts, not who wrote it. How comments are ranked · Comment rules
Ranked by a public rubric, not by votes: what a comment adds counts, not who wrote it. How comments are ranked · Comment rules
Summary
The article explains how database replication works in Postgres, covering what the primary sends to replicas, why physical replication uses raw write-ahead log records instead of replayed SQL, how replicas apply the log and track their position via LSNs, how replication slots protect needed WAL, and the tradeoffs between synchronous…