Re: Extension Enhancement: Buffer Invalidation in pg_buffercache

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема Re: Extension Enhancement: Buffer Invalidation in pg_buffercache
Дата
Msg-id CA+hUKG+CjngU9+7mfPsV6tA8Rze9keoV887mHxUL_9qiFUrjJA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Extension Enhancement: Buffer Invalidation in pg_buffercache  (Thomas Munro <thomas.munro@gmail.com>)
Ответы Re: Extension Enhancement: Buffer Invalidation in pg_buffercache  (Melanie Plageman <melanieplageman@gmail.com>)
Re: Extension Enhancement: Buffer Invalidation in pg_buffercache  (Andres Freund <andres@anarazel.de>)
Re: Extension Enhancement: Buffer Invalidation in pg_buffercache  (Maksim Milyutin <milyutinma@gmail.com>)
Список pgsql-hackers
On second thoughts, I think the original "invalidate" terminology was
fine, no need to invent a new term.

I thought of a better name for the bufmgr.c function though:
InvalidateUnpinnedBuffer().  That name seemed better to me after I
festooned it with warnings about why exactly it's inherently racy and
only for testing use.

I suppose someone could propose an additional function
pg_buffercache_invalidate(db, tbspc, rel, fork, blocknum) that would
be slightly better in the sense that it couldn't accidentally evict
some innocent block that happened to replace the real target just
before it runs, but I don't think it matters much for this purpose and
it would still be racy on return (vacuum decides to load your block
back in) so I don't think it's worth bothering with.

So this is the version I plan to commit.

Вложения

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

Предыдущее
От: Jelte Fennema-Nio
Дата:
Сообщение: Re: Flushing large data immediately in pqcomm
Следующее
От: David Rowley
Дата:
Сообщение: Re: Add bump memory context type and use it for tuplesorts