pgsql: Fix lazy_scan_heap so that it won't mark pages all-frozen too so

Поиск
Список
Период
Сортировка
От Robert Haas
Тема pgsql: Fix lazy_scan_heap so that it won't mark pages all-frozen too so
Дата
Msg-id E1bDFbL-0002Os-Ck@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Fix lazy_scan_heap so that it won't mark pages all-frozen too soon.

Commit a892234f830e832110f63fc0a2afce2fb21d1584 added a new bit per
page to the visibility map fork indicating whether the page is
all-frozen, but incorrectly assumed that if lazy_scan_heap chose to
freeze a tuple then that tuple would not need to later be frozen
again. This turns out to be false, because xmin and xmax (and
conceivably xvac, if dealing with tuples from very old releases) could
be frozen at separate times.

Thanks to Andres Freund for help in uncovering and tracking down this
issue.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/38e9f90a227d1e60e7b4691d1a71fefaba6059e5

Modified Files
--------------
src/backend/access/heap/heapam.c  | 45 ++++++++++++++++++++++++++++-----------
src/backend/commands/vacuumlazy.c |  8 +++++--
src/include/access/heapam_xlog.h  |  3 ++-
3 files changed, 40 insertions(+), 16 deletions(-)


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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: [HACKERS] Re: pgsql: Avoid extra locks in GetSnapshotData if old_snapshot_threshold <
Следующее
От: Kevin Grittner
Дата:
Сообщение: Re: [HACKERS] Re: pgsql: Avoid extra locks in GetSnapshotData if old_snapshot_threshold <