« All posts

Read Your Writes: Introducing WAIT FOR in PostgreSQL 19

The WAIT FOR command in PostgreSQL 19 ensures read-your-writes consistency on async replicas.

PostgreSQL 19 introduces the WAIT FOR SQL command, which allows a session to block until a specific WAL position is reached. This provides read-your-writes consistency on asynchronous replicas without the downsides of synchronous replication. By using WAIT FOR, applications can ensure that reads reflect the most recent writes without incurring additional latency for every commit.

This synthesis was produced from its source by AI; there is no human editor or manual review step. How we work