PostgreSQL 19 introduces four new system views for observability: pg_stat_lock provides cumulative cluster-wide lock contention statistics per lock type, including a fastpath_exceeded counter useful for partition-heavy workloads; pg_stat_recovery gives a single atomic snapshot of standby recovery state (replay LSNs, timelines, pause state, promotion status), replacing the need to combine several inconsistent functions;pg_stat_autovacuum_sc exposes the new per-table scoring system (based on XID age, multixact age, dead tuples, inserts, and analyze staleness) that now determines autovacuum table processing order, replacing the old pg_class ordering; and pg_dsm_registry_allocations lists dynamic shared memory registry entries (name, type, size) used by extensions that no longer need shared_preload_libraries and a restart. The piece walks through each view's schema and runs live demo queries showing sample output. PostgreSQL 19 is still in beta and details may change before GA.
Post #2318
13.9K

New system views in PostgreSQL 19
- ❤ 15
- 👍 1