Re: Pruning never visible changes

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Pruning never visible changes
Дата
Msg-id 3677239.1663338389@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Pruning never visible changes  (Simon Riggs <simon.riggs@enterprisedb.com>)
Ответы Re: Pruning never visible changes  (Simon Riggs <simon.riggs@enterprisedb.com>)
Re: Pruning never visible changes  (Laurenz Albe <laurenz.albe@cybertec.at>)
Re: Pruning never visible changes  (Greg Stark <stark@mit.edu>)
Список pgsql-hackers
Simon Riggs <simon.riggs@enterprisedb.com> writes:
> A user asked me whether we prune never visible changes, such as
> BEGIN;
> INSERT...
> UPDATE.. (same row)
> COMMIT;

Didn't we just have this discussion in another thread?  You cannot
do that, at least not without checking that the originating
transaction has no snapshots that could see the older row version.
I'm not sure whether or not snapmgr.c has enough information to
determine that, but in any case this formulation is surely
unsafe, because it isn't even checking whether that transaction is
our own, let alone asking snapmgr.c.

I'm dubious that a safe version would fire often enough to be
worth the cycles spent.

            regards, tom lane



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

Предыдущее
От: Maxim Orlov
Дата:
Сообщение: Re: Add 64-bit XIDs into PostgreSQL 15
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: [PoC] Let libpq reject unexpected authentication requests