PostgreSQL 19 adds REPACK CONCURRENTLY, pg_plan_advice, and read-your-writes standby consistency
PostgreSQL 19 replaces blocking VACUUM FULL with online REPACK, adds query plan stabilization without application changes, and enables read-your-writes consistency across primary-standby deployments.
Summary
The PostgreSQL Global Development Group released PostgreSQL 19 on November 19, 2026, targeting mission-critical workloads with features that reduce operational disruption and improve distributed application reliability. The release introduces REPACK (CONCURRENTLY), which reclaims table bloat and reorders data to match indexes without blocking reads or writes, replacing the locking behavior of VACUUM FULL and CLUSTER. A new pg_plan_advice extension pair allows database administrators to stabilize query plans and apply fixes via query identifiers without modifying application code.
For distributed deployments, PostgreSQL 19 eliminates server restarts to enable logical replication by automatically raising the WAL level when creating the first replication slot. The release adds WAIT FOR LSN for read-your-writes consistency on standbys, logical replication of sequence values, and foreign server-based subscription connections. Autovacuum gains parallel index vacuuming and a scoring-based prioritization system, while monitoring improves with new statistics views for locks, recovery status, and autovacuum decisions.
Storage, planning, and replication changes in PostgreSQL 19
- REPACK command: Replaces VACUUM FULL and CLUSTER with online table reorganization; REPACK (CONCURRENTLY) reclaims bloat and reorders data to match an index without blocking reads or writes, while the old commands remain for compatibility.
- Query plan stabilization: The pg_plan_advice extension enables plan choice stabilization and experimentation through a plan advice mini-language; pg_stash_advice stores advice and auto-applies it by query identifier, decoupling plan fixes from application deployments.
- Autovacuum parallelism and scoring: Autovacuum now vacuums indexes using parallel workers controlled by autovacuum_max_parallel_workers, prioritizes tables via a new scoring system, and benefits from queries automatically marking pages all-visible during execution.
- Logical replication simplification: The effective WAL level automatically escalates to logical upon first logical replication slot creation, eliminating server restarts; new features include sequence value replication via FOR ALL SEQUENCES, EXCEPT clauses in CREATE PUBLICATION, and SERVER clause subscriptions using postgres_fdw foreign server definitions.
- Standby consistency and monitoring: WAIT FOR LSN enables read-your-writes consistency by allowing standby sessions to wait for specific WAL replay positions; new monitoring views include pg_stat_lock, pg_stat_recovery, pg_stat_autovacuum_scores, and IO reporting in EXPLAIN ANALYZE for async I/O activity.
Why it matters
PostgreSQL 19 directly reduces operational pain for Linux distribution packagers, managed database providers, and site reliability engineers who previously scheduled maintenance windows for VACUUM FULL operations on large tables. The decoupling of query plan fixes from application deployments via pg_plan_advice lowers the barrier to performance stabilization in containerized and cloud-native environments where application code changes require CI/CD cycles. Combined with zero-downtime logical replication initialization and cross-node read consistency, these changes strengthen PostgreSQL's position as the default open-source relational database for distributed systems and high-availability Linux infrastructure.
What to do
- Update to PostgreSQL 19 to replace blocking VACUUM FULL with online REPACK (CONCURRENTLY) for table maintenance without downtime.
- Enable pg_plan_advice and pg_stash_advice extensions to stabilize query plans and apply fixes by query identifier without changing application code.
- Use WAIT FOR LSN on standby servers to achieve read-your-writes consistency for applications that distribute reads across primary-standby deployments.
- Set autovacuum_max_parallel_workers to enable parallel index vacuuming, and monitor autovacuum prioritization via the new pg_stat_autovacuum_scores view.
Original reference: www.postgresql.org →