Production problem:
an e-commerce order database may need a major-version migration or a financial-services reporting workload may need to move away from the transactional database, while the existing application continues accepting writes.
Design goal:
build and validate the target while keeping the source live, then make the final cutover only once the target has caught up sufficiently.
Architecture:
PostgreSQL logical replication uses a publisher/subscriber model. Existing rows are initially synchronized and subsequent changes continue through the replication stream.
PostgreSQL explicitly lists cross-major-version migration, data distribution and moving subsets of a database as typical uses.
Additional Note:
WAL in PostgreSQL stands for Write-Ahead Logging, a standard method used to ensure data integrity and durability. In short, WAL records all changes to the database (in a fast memory area called shared buffers) before the actual data pages are written to disk.

Top comments (0)