Re: test: avoid redundant standby catchup in 049_wait_for_lsn

From: Alexander Korotkov <aekorotkov(at)gmail(dot)com>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Xuneng Zhou <xunengzhou(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: test: avoid redundant standby catchup in 049_wait_for_lsn
Date: 2026-04-18 08:02:12
Message-ID: CAPpHfdsUsS6HVt3F-i+VCZEciqBY_HLZ28hbSoh=gwqXQdr=MQ@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi, Michael!

On Sat, Apr 18, 2026 at 12:47 AM Michael Paquier <michael(at)paquier(dot)xyz> wrote:
>
> On Fri, Apr 17, 2026 at 08:25:35PM +0800, Xuneng Zhou wrote:
> > The change preserves the same coverage while removing one redundant
> > replay catch-up on the delayed standby. It appears to reduce the test
> > runtime by about 7 seconds, though I have looked into why much of the
> > improvement comes from this change alone.
>
> Alexander may think differently and remove that, but I disagree. The
> test is clearly written so as we want two wait checks to happen, for
> for CREATE FUNCTION, and one for CREATE PROCEDURE. Removing the first
> check to keep only the second one removes its meaning. In short, I
> see nothing wrong to deal with here.

Thank you for your observation. The intention of this test is to
check explicit calls to WAIT FOR LSN. Yes, wait_for_catchup() now
also internally calls WAIT FOR LSN. But checking wait_for_catchup()
is not intention of this test, it's used in awfully a lot of other
places.

------
Regards,
Alexander Korotkov
Supabase

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message David Rowley 2026-04-18 09:06:02 Re: [PATCH] Add tests for Bitmapset
Previous Message Alexander Korotkov 2026-04-18 07:58:42 Re: test: avoid redundant standby catchup in 049_wait_for_lsn