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

Поиск
Список
Период
Сортировка
От Anna Akenteva
Тема Re: [HACKERS] make async slave to wait for lsn to be replayed
Дата
Msg-id e544ce8b7e6ceadf6bb89094aef68c26@postgrespro.ru
обсуждение исходный текст
Ответ на Re: [HACKERS] make async slave to wait for lsn to be replayed  (Kartyshov Ivan <i.kartyshov@postgrespro.ru>)
Ответы Re: [HACKERS] make async slave to wait for lsn to be replayed
Список pgsql-hackers
On 2020-04-07 00:58, Kartyshov Ivan wrote:
> Ok, here is a new version of patch with single LSN and TIMEOUT.

I had a look at the code and did some more code cleanup, with Ivan's 
permission.
This is what I did:
- Removed "WAIT FOR" command tag from cmdtaglist.h and renamed WaitStmt 
to WaitClause (since there's no standalone WAIT FOR command anymore)
- Added _copyWaitClause() and _equalWaitClause()
- Removed unused #include-s from utility.c
- Adjusted tests and documentation
- Fixed/added some code comments

I have a couple of questions about WaitUtility() though:
- When waiting forever (due to not specifying a timeout), isn't 60 
seconds too long of an interval to check for interrupts?
- If we did specify a timeout, it might be a very long one. In this 
case, shouldn't we also make sure to wake up sometimes to check for 
interrupts?
- Is it OK that specifying timeout = 0 (BEGIN WAIT FOR LSN ... TIMEOUT 
0) is the same as not specifying timeout at all?

-- 
Anna Akenteva
Postgres Professional:
The Russian Postgres Company
http://www.postgrespro.com
Вложения

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [PATCH] Incremental sort (was: PoC: Partial sort)
Следующее
От: Jeff Davis
Дата:
Сообщение: Re: Make MemoryContextMemAllocated() more precise