Re: [HACKERS] make async slave to wait for lsn to be replayed

From: Alexander Korotkov <aekorotkov(at)gmail(dot)com>
To: Peter Eisentraut <peter(at)eisentraut(dot)org>
Cc: Kartyshov Ivan <i(dot)kartyshov(at)postgrespro(dot)ru>, pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: [HACKERS] make async slave to wait for lsn to be replayed
Date: 2024-03-26 23:49:17
Message-ID: CAPpHfdv8zAqTuRzOXgn2yKc4O8qJmfzeJ37975+QecixVjS4oA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Mar 22, 2024 at 12:50 AM Peter Eisentraut <peter(at)eisentraut(dot)org> wrote:
> On 19.03.24 18:38, Kartyshov Ivan wrote:
> > CALL pg_wait_lsn('0/3002AE8', 10000);
> > BEGIN;
> > SELECT * FROM tbl; // read fresh insertions
> > COMMIT;
>
> I'm not endorsing this or any other approach, but I think the timeout
> parameter should be of type interval, not an integer with a unit that is
> hidden in the documentation.

I'm not sure a timeout needs to deal with complexity of our interval
datatype. At the same time, the integer number of milliseconds looks
a bit weird. Could the float8 number of seconds be an option?

------
Regards,
Alexander Korotkov

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Nathan Bossart 2024-03-26 23:55:54 Re: add AVX2 support to simd.h
Previous Message Alexander Korotkov 2024-03-26 23:39:04 Re: Add SPLIT PARTITION/MERGE PARTITIONS commands