Re: ERROR after writing PREPARE WAL record

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: ERROR after writing PREPARE WAL record
Дата
Msg-id 26087.1563370640@sss.pgh.pa.us
обсуждение исходный текст
Ответ на ERROR after writing PREPARE WAL record  (Asim R P <apraveen@pivotal.io>)
Ответы Re: ERROR after writing PREPARE WAL record  (Asim R P <apraveen@pivotal.io>)
Список pgsql-hackers
Asim R P <apraveen@pivotal.io> writes:
> Cancel/terminate requests are held off during "PREPARE TRANSACTION"
> processing in function PrepareTransaction().  However, a subroutine invoked
> by PrepareTransaction() may perform elog(ERROR) or elog(FATAL).

Doing anything that's likely to fail in the post-commit code path is
a Bad Idea (TM).  There's no good recovery avenue, so the fact that
you generally end up at a PANIC is expected/intentional.

The correct response, if you notice code doing that, is to fix it so
it doesn't do that.  Typically the right answer is to move the
failure-prone operation to pre-commit processing.

            regards, tom lane



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

Предыдущее
От: Nikita Glukhov
Дата:
Сообщение: Re: Ltree syntax improvement
Следующее
От: Jeevan Chalke
Дата:
Сообщение: Re: block-level incremental backup