pg_waldump: Preparatory refactoring for tar archive WAL decoding.
Andrew Dunstan <andrew@dunslane.net>
pg_waldump: Preparatory refactoring for tar archive WAL decoding. Several refactoring steps in preparation for adding tar archive WAL decoding support to pg_waldump: - Move XLogDumpPrivate and related declarations into a new pg_waldump.h header, allowing a second source file to share them. - Factor out required_read_len() so the read-size calculation can be reused for both regular WAL files and tar-archived WAL. - Move the WAL segment size variable into XLogDumpPrivate and rename it to segsize, making it accessible to the archive streamer code. Author: Amul Sul <sulamul@gmail.com> Reviewed-by: Robert Haas <robertmhaas@gmail.com> Reviewed-by: Jakub Wartak <jakub.wartak@enterprisedb.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Euler Taveira <euler@eulerto.com> Reviewed-by: Andrew Dunstan <andrew@dunslane.net> discussion: https://postgr.es/m/CAAJ_b94bqdWN3h2J-PzzzQ2Npbwct5ZQHggn_QoYGhC2rn-=WQ@mail.gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/bin/pg_waldump/pg_waldump.c | modified | +44 −34 |
| src/bin/pg_waldump/pg_waldump.h | added | +26 −0 |
Discussion
- pg_waldump: support decoding of WAL inside tarfile 126 messages · 2025-08-07 → 2026-04-15