| From: | Zsolt Parragi <zsolt(dot)parragi(at)percona(dot)com> |
|---|---|
| To: | Andrey Borodin <x4mmm(at)yandex-team(dot)ru> |
| Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org, Michael Paquier <michael(at)paquier(dot)xyz>, Japin Li <japinli(at)hotmail(dot)com> |
| Subject: | Re: Compression of bigger WAL records |
| Date: | 2026-10-26 23:39:53 |
| Message-ID: | CAN4CZFOhMg9oyKUSeK4VhdB1B-cOjS6qUgTk9HCDnbMg9pLQHQ@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
- decoded = XLogReadRecordAlloc(state,
- total_len,
- false /* allow_oversized */ );
+ if (have_decomp_len)
+ decoded = XLogReadRecordAlloc(state,
+ total_len_decomp,
+ false /* allow_oversized */ );
+
Won't this result in a performance regression with the additional
blocks when the header crosses multiple pages?
+/* Read length of a record, accounting for possible compression */
+static uint32
+XLogGetRecordTotalLen(XLogRecord *record)
+{
+ if (record->xl_info & XLR_COMPRESSED)
Shouldn't this flag be unset after decompression? Or alternatively
some existing code needs fixing, for example replorigin_identity
doesn't do any masking (but above it replorigin_desc does, so that by
itself seems somewhat inconsistent)
And: it seems like that the patchset tries to compress incompressible
FPI records twice (first record, then whole page, failing both times)?
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Bruce Momjian | 2026-10-26 23:47:01 | Re: First draft of PG 19 release notes |
| Previous Message | Jeremy Schneider | 2026-10-26 23:24:20 | Re: Skip prefetch for block references that follow a FPW or WILL_INIT of the same block |