Re: Wrong LSN in WAL decoding error messages

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: surya poondla <suryapoondla4(at)gmail(dot)com>
Cc: Rahul <rahul(at)rhyadav(dot)dev>, Pgsql Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Ju Grigorev <ju(dot)grigorev(at)ftdata(dot)ru>
Subject: Re: Wrong LSN in WAL decoding error messages
Date: 2026-10-30 14:59:43
Message-ID: CAHGQGwHMpEVHPkm5heObEZaaG8=M9kOLc37-zUrteaptgi7MMg@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Oct 13, 2026 at 3:07 AM surya poondla <suryapoondla4(at)gmail(dot)com> wrote:
> The patch looks ready for a Committer.

DecodeXLogRecord() changes in 0001 patch look good to me.

But, do we really need a new test for such a small fix? Generating and
locating a record, handling boundaries, modifying WAL, recomputing the CRC,
and copying the segment seem like a lot of complexity and maintenance
overhead just to verify the reported LSN, I'm afraid.

If we really want this, seems it's better to consider it separately as a test
for malformed WAL detection, including the LSN check. I'm just not sure
this additional infrastructure is worth the effort, though..

Regards,

--
Fujii Masao

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2026-10-30 15:07:26 Re: Return INT_MAX or INT_MIN from strtoint() on overflow
Previous Message Sami Imseih 2026-10-30 14:41:12 Re: [PATCH] pgstat: Add helper to drop entries from a stats kind's hash