by jvdongen · 3y ago · 0 comments
As explained in the docs you link to, Postgres has both synchronous and asynchronous replication modes.
In asynchronous mode availability is favored over durability. Which means commits can get lost when the primary goes down in an uncontrolled fashion.
In sync mode that will not happen at a cost to some performance.
It’s the same trade-off any distributed system has to make, and the user gets to make the choice.
You can also mix and match sync/ascync options within a cluster and even between individual transactions.
Recent versions of Postgres have a really flexible replication configuration to cover a whole range of requirements. See e.g. https://www.postgresql.org/docs/current/warm-standby.html#SY...