Synchronous vs Asynchronous Replication
Understand the durability and latency trade-offs between synchronous and asynchronous physical replication in PostgreSQL.
Two Modes of Streaming
Physical streaming replication can run in two modes: asynchronous (the default) and synchronous. They differ in when the primary considers a commit complete.
Asynchronous Replication
In async mode the primary commits as soon as the WAL is flushed locally. It does not wait for the standby. This is fast but a crash can lose the most recent commits not yet shipped.
All lessons in this course
- Understanding Replication Concepts
- Physical Replication (Streaming)
- Setting Up a Standby Server
- Synchronous vs Asynchronous Replication