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

Поиск
Список
Период
Сортировка
От Kartyshov Ivan
Тема Re: [HACKERS] make async slave to wait for lsn to be replayed
Дата
Msg-id ccdc6c31218f61a2970c84cc850c8a41@postgrespro.ru
обсуждение исходный текст
Ответ на Re: [HACKERS] make async slave to wait for lsn to be replayed  (Alexander Korotkov <a.korotkov@postgrespro.ru>)
Ответы Re: [HACKERS] make async slave to wait for lsn to be replayed
Список pgsql-hackers
On 2020-04-08 00:27, Tom Lane wrote:
> Alexander Korotkov <akorotkov@postgresql.org> writes:
»   WAIT FOR LSN lsn [ TIMEOUT timeout ]
> 
> This seems like a really carelessly chosen syntax —- *three* new
> keywords, when you probably didn't need any.  Are you not aware that
> there is distributed overhead in the grammar for every keyword?
> Plus, each new keyword carries the risk of breaking existing
> applications, since it no longer works as an alias-not-preceded-by-AS.
> 

To avoid creating new keywords, we could change syntax in the following 
way:
WAIT FOR => DEPENDS ON
LSN => EVENT
TIMEOUT => WITH INTERVAL

So
START TRANSACTION WAIT FOR LSN '0/3F07A6B1' TIMEOUT 5000;
would instead look as
START TRANSACTION DEPENDS ON EVENT '0/3F07A6B1' WITH INTERVAL '5 
seconds';

[1] 
https://www.postgresql.org/message-id/28209.1586294824%40sss.pgh.pa.us

-- 
Ivan Kartyshov
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Peter Geoghegan
Дата:
Сообщение: Re: Using the rr debugging tool to debug Postgres
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: pgsql: Allow users to limit storage reserved by replication slots